Commit Graph

477 Commits

Author SHA1 Message Date
Chani Armitage
bf8eb6de86 Revert "give contextmenuevent a chance to run"
ooops. that patch relies on 4.6, didn't mean to commit it yet

svn path=/trunk/KDE/kdelibs/; revision=1018488
2009-09-01 18:46:28 +00:00
Chani Armitage
0afd8efd8c give contextmenuevent a chance to run
this is icky and depends on scene()->sendEvent
but we need it to know whether the containment plugin has child items
expecting a contextmenuevent, before we eat the event.
by the time contextmenuevent runs normally it's too late.

svn path=/trunk/KDE/kdelibs/; revision=1018486
2009-09-01 18:42:26 +00:00
Chani Armitage
eab10293a8 consider the handle part of the applet for mouseevents
svn path=/trunk/KDE/kdelibs/; revision=1017591
2009-08-30 23:41:23 +00:00
Chani Armitage
024d23a07f for contextmenu events triggered by the mouse on the containment, fall
through to the mouse events. it's easier to handle that way

svn path=/trunk/KDE/kdelibs/; revision=1017492
2009-08-30 18:52:10 +00:00
Chani Armitage
93aead97a1 allow click-throughs for the containment's graphicsitems
this makes folderview happier, yay

svn path=/trunk/KDE/kdelibs/; revision=1017491
2009-08-30 18:52:05 +00:00
Chani Armitage
f725121a2a don't use qgraphicsitem_cast, + some cleanup
svn path=/trunk/KDE/kdelibs/; revision=1017490
2009-08-30 18:51:58 +00:00
Chani Armitage
22506da412 make rightclick-on-folderview work
svn path=/trunk/KDE/kdelibs/; revision=1017489
2009-08-30 18:51:51 +00:00
Chani Armitage
af4925f777 SVN_SILENT: less negative
svn path=/trunk/KDE/kdelibs/; revision=1017488
2009-08-30 18:51:32 +00:00
Aaron J. Seigo
87b743188e update the toolbox when the activity changes as it may be showing the name of it
svn path=/trunk/KDE/kdelibs/; revision=1016743
2009-08-28 19:07:56 +00:00
Aaron J. Seigo
1f57b0c726 send in both press and release events
svn path=/trunk/KDE/kdelibs/; revision=1015482
2009-08-25 16:14:05 +00:00
Aaron J. Seigo
de4e6d5bf1 remove the handle from the scene before deleting it; this prevents full screen repaints whenever a widget has the mouse passed over it. will backport.
svn path=/trunk/KDE/kdelibs/; revision=1012691
2009-08-17 23:40:07 +00:00
Chani Armitage
0ecafe8131 use trigger for config group
svn path=/trunk/KDE/kdelibs/; revision=1012648
2009-08-17 22:31:37 +00:00
Chani Armitage
2ab601f945 various bits of cleanup:
load requires a containment
    fix @since (I could've sworn I did this already..)
    rename ContextAction->ContainmentActions
    misc. improvements from aaron
    no more warnings
    qDeleteAll
    don't iterate with keys()

svn path=/trunk/KDE/kdelibs/; revision=1012647
2009-08-17 22:31:32 +00:00
Chani Armitage
ae2378a8da some code cleanup
fix copyright
    always init a contextaction before trying to use it
    no more unexpected click-throughs
    contextAction() returns the plugin name instead of a pointer

svn path=/trunk/KDE/kdelibs/; revision=1012645
2009-08-17 22:31:18 +00:00
Chani Armitage
5070e300f5 API changes needed for configurable contextmenu.
-setContainment, so that we don't have to try and use the parent any
more.
-hasConfigurationInterface; this should've already been there.
-default values for a couple of functions that I think make sense

svn path=/trunk/KDE/kdelibs/; revision=1012644
2009-08-17 22:31:08 +00:00
Chani Armitage
69365ddada paste is triggered by a plugin now.
also, clean up the drop/paste handling a bit

svn path=/trunk/KDE/kdelibs/; revision=1012643
2009-08-17 22:31:03 +00:00
Chani Armitage
464df207d1 API review stuff
-have one virtual QEvent function
-move eventToString to ContextAction
-remove needsConfig reason
-remove configurationAction
-remove dataengine stuff

svn path=/trunk/KDE/kdelibs/; revision=1012642
2009-08-17 22:30:58 +00:00
Chani Armitage
d82fe71821 stuff needed for configuration of plugins
svn path=/trunk/KDE/kdelibs/; revision=1012641
2009-08-17 22:30:54 +00:00
Chani Armitage
9d2a2e40ba api review part 1
removed some dead signals and an unnecessary const

svn path=/trunk/KDE/kdelibs/; revision=1012640
2009-08-17 22:30:50 +00:00
Chani Armitage
f0a68d537c make rightclick plugins possible
this makes rightclicks use the plugin configured for rightclick
and adds a new method to the plugin for when an applet is rightclicked
(we need a list of actions then that we can insert into the menu)
this also adds a signal for immutability and improves handling of
needs-configuring plugins

svn path=/trunk/KDE/kdelibs/; revision=1012639
2009-08-17 22:30:46 +00:00
Chani Armitage
a848e4fdcf make config restore work.
svn path=/trunk/KDE/kdelibs/; revision=1012638
2009-08-17 22:30:42 +00:00
Chani Armitage
7da00b4c7c API needed for the config dialog
I factored out eventToString into a static function
and also added @since tags to all my functions

svn path=/trunk/KDE/kdelibs/; revision=1012637
2009-08-17 22:30:38 +00:00
Chani Armitage
493196dff3 use contextaction plugins.
there are a few defaults, only one real plugin exists so far
rightclicks are still overridden by the contextmenu event.
the user is warned about plugins that need configuring.

svn path=/trunk/KDE/kdelibs/; revision=1012636
2009-08-17 22:30:34 +00:00
Sebastian Kügler
5ea600487a Make dropping remote content onto Plasma work
The idea is that you drop a file from a webpage, or basically a URL onto Plasma and Plasma creates a suitable applet to display this URL. For example an image frame for picture, or a previewer for pdf files. Downloading the data itself (and possibly saving it) is left to the applets. The mimetype needs to be retrieved as it cannot be determined from the URL.

The code pathes I've changed or added are, roughly:
- "something" is dropped onto Plasma
- if it's a remote URL, we don't know the mimetype of the object behind the URL yet
- a KIO::TransferJob is used to retrieve the mimetype asynchronously, and will call back
- we open a QMenu that says "Fetching file type..."
- If the user closes the menu while the mimetype is being retrieved, we will open a new one
- When the TransferJob calls back, and we have our mimetype, we offer a list of applets suitable for this kind of content
- If the user chooses to create an applet, we put the transfer job on hold to make it available for recycling by the applet
- If the user dismisses the offering, we kill the job

Thanks to marco for reviewing and everybody else for the input :)

Next steps are making some more applets work with this.

CCMAIL:plasma-devel@kde.org


svn path=/trunk/KDE/kdelibs/; revision=1009004
2009-08-08 22:01:16 +00:00
Aaron J. Seigo
0de5d23864 let the applet do the thinking about wether or not the config action is enabled
CCBUG:201663

svn path=/trunk/KDE/kdelibs/; revision=1003317
2009-07-28 01:09:17 +00:00
Aaron J. Seigo
18959b552a in RTL, the geometries are reversed; compare them with that taken into consideration
BUG:187406

svn path=/trunk/KDE/kdelibs/; revision=992935
2009-07-08 00:37:40 +00:00
Laurent Montel
22a3d92cdc const'ify
svn path=/trunk/KDE/kdelibs/; revision=992163
2009-07-06 11:49:01 +00:00
Aaron J. Seigo
a179a16a9e only close the desktop toolbox if the action is non-repeatable, which implies it's a fire-and-forget type of action such as something that triggers a dialog
BUG:198229

svn path=/trunk/KDE/kdelibs/; revision=988884
2009-06-29 01:22:58 +00:00
Aaron J. Seigo
c63f672d49 cean this up a little bit
svn path=/trunk/KDE/kdelibs/; revision=982722
2009-06-16 17:46:32 +00:00
Marco Martin
06c17a9583 emit activate when the screen changes and is actually an used screen
svn path=/trunk/KDE/kdelibs/; revision=982318
2009-06-15 13:58:23 +00:00
Marco Martin
b3c9d74f0a correctly restore the toolbox whaen a different config file is used (for
the first load)

svn path=/trunk/KDE/kdelibs/; revision=982317
2009-06-15 13:57:46 +00:00
Aaron J. Seigo
8907a1306b more careful with the actions
svn path=/trunk/KDE/kdelibs/; revision=979529
2009-06-10 04:51:24 +00:00
Marco Martin
299d00c193 reverting this bit committed by mistake
svn path=/trunk/KDE/kdelibs/; revision=977600
2009-06-04 19:49:36 +00:00
Marco Martin
ed608afc54 don't mess with size policies applets have chosen, at least with
ignoreaspectRatio applets
(aspectratio and sizepolicy sounds really colliding concepts ah, 4.0
leftovers i love you)

svn path=/trunk/KDE/kdelibs/; revision=977593
2009-06-04 19:00:16 +00:00
Aaron J. Seigo
d5ce775e22 save the desktop setting when it changes in setScreen just as we do for the screen
CCBUG:192245

svn path=/trunk/KDE/kdelibs/; revision=976441
2009-06-01 17:30:52 +00:00
Eduard Vladislavovich Sukharev
bca2659a0e fixing crash on Win and (possibly) Mac when middle mouse clicked on plasma Containment
svn path=/trunk/KDE/kdelibs/; revision=971575
2009-05-22 19:22:57 +00:00
Marco Martin
87d8831b2e set the geometry and then add the offscreen containment to corona->no
more colliding calendars

svn path=/trunk/KDE/kdelibs/; revision=970798
2009-05-20 20:27:01 +00:00
Darío Andrés Rodríguez
479203d54f Call setParent() after the m_wallpaper pointer check
BUG: 192912

svn path=/trunk/KDE/kdelibs/; revision=969230
2009-05-17 18:23:31 +00:00
Aaron J. Seigo
4ea997a9f1 don't crash when moving the focused applet from one containment to another
BUG:192589

svn path=/trunk/KDE/kdelibs/; revision=967669
2009-05-13 18:11:08 +00:00
Aaron J. Seigo
5f7fb0c500 prevent getting called twice (fixes crash on removing panels)
svn path=/trunk/KDE/kdelibs/; revision=964500
2009-05-06 19:08:29 +00:00
Aaron J. Seigo
6ca62962e2 do a sweep for kapplication usage
svn path=/trunk/KDE/kdelibs/; revision=963961
2009-05-05 18:11:50 +00:00
Chani Armitage
571367cec2 middle-click pastes data onto containments now :)
svn path=/trunk/KDE/kdelibs/; revision=963659
2009-05-05 05:19:35 +00:00
Chani Armitage
233e220ad9 safer way of creating actions, according to mjansen
svn path=/trunk/KDE/kdelibs/; revision=963095
2009-05-03 22:13:05 +00:00
Chani Armitage
c756fd29c4 configurable keyboard shortcuts
svn path=/trunk/KDE/kdelibs/; revision=963051
2009-05-03 20:22:14 +00:00
Aaron J. Seigo
9339d4e96a go back to the plugin info categories
svn path=/trunk/KDE/kdelibs/; revision=962195
2009-05-01 18:01:26 +00:00
Aaron J. Seigo
0b5c4e1947 use Keywords instead of X-KDE-PluginInfo-Category so we can be translated and even support multiple categories!
svn path=/trunk/KDE/kdelibs/; revision=961933
2009-05-01 05:36:50 +00:00
Aaron J. Seigo
7d8a4272cd put containment options last, make accidental removal of widgets a bit harder
BUG:188880

svn path=/trunk/KDE/kdelibs/; revision=960594
2009-04-28 17:30:46 +00:00
Aaron J. Seigo
6d7622271c * Toolbox -> ToolBox
* emit the signals only when things change

svn path=/trunk/KDE/kdelibs/; revision=958822
2009-04-24 19:27:58 +00:00
Aaron J. Seigo
718c24af43 correct connect statements
svn path=/trunk/KDE/kdelibs/; revision=958270
2009-04-23 16:38:16 +00:00
Marco Martin
43af4a45b4 signal void toolBoxVisibilityChanged(bool); that notifies when the
toolbox gets open/closed

svn path=/trunk/KDE/kdelibs/; revision=953372
2009-04-13 20:26:17 +00:00