Commit Graph

3494 Commits

Author SHA1 Message Date
andreas kainz
95f01093ac update ktorrent icon
BUG: 369302
2016-09-25 23:00:18 +02:00
l10n daemon script
19c89d0b0c SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-09-23 09:35:12 +00:00
Mihail Ivchenko
edf0d68ea5 [WindowThumbnail] Discard pixmap on map events.
According to [X.org
docs](http://www.x.org/releases/X11R7.7/doc/compositeproto/compositeproto.txt)
regarding NameWindowPixmap:

"This pixmap will remain allocated until freed, even if 'window' is
unmapped, reconfigured or destroyed. However, 'window' will get a new
pixmap allocated each time it is mapped or resized, so this request will
need to be reinvoked"

So, pixmap needs to be discarded not only on XCB_CONFIGURE_NOTIFY event
but on XCB_MAP_NOTIFY event also.
2016-09-22 21:29:42 +01:00
David Edmundson
494c690b18 Don't include kdeglobals when dealing with a cache config
The svg elements cache isn't really a "configuration" and it's not
something that should be overridden by global config settings.

Loading it as a simple config skips the cascading and saves reparsing
kdeglobals.

REVIEW: 128966
2016-09-21 11:43:50 +01:00
David Edmundson
16b478a827 Fix Plasma::knownLanguages
There was a logic error meaning this did the exact opposite of what
it should have been doing.

Fortunately no-one calls it anywhere.

REVIEW: 128959
2016-09-20 14:31:29 +01:00
David Edmundson
580af56fe5 Minor optimisation/cleanup in scripengine loading
Avoid creating a KPLuginInfo list from KPluginMetaData

REVIEW: 128955
2016-09-20 14:30:30 +01:00
Marco Martin
8f10b73cc1 resize the view just after setting the containment
when the view is in SizeRootObjectToView mode, the root
object is resized in the event handler, that is too late at startup.
resize the root object right after having announced
the new containment, so the view subclass can have
the view resized to the proper size beforehand,
removing an useless containment graphicsobject resize.

REVIEW:128915
2016-09-15 13:05:24 +02:00
l10n daemon script
6837a1c855 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-09-15 09:46:00 +00:00
David Edmundson
820baec72e Avoid creating a KPluginInfo from a KPluginMetaData instance
It's not needed, gives a (very) tiny performance boost and is a bit
cleaner.

REVIEW: 128904
2016-09-14 13:39:10 +01:00
l10n daemon script
861f1c982a SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-09-14 09:18:35 +00:00
Christophe Giboudeaux
8f980541f5 Don't install files twice. 2016-09-10 14:14:43 +02:00
Marco Martin
c35d5b1d48 running tasks must have some indicator
running tasks need to have some visual indicator,
otherwise is impossible to distinguish between
tasks and launchers in icontasks

Change-Id: Ib1c319c675855a605d8a268bad2bb43ad19a6e4d
2016-09-09 16:20:26 +02:00
andreas kainz
8c72b9515e task bar lines according to RR 128802 marco give the ship it
REVIEW: 128802
2016-09-09 12:20:59 +02:00
l10n daemon script
71b8f9b22d SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-09-09 09:25:38 +00:00
Kai Uwe Broulik
dd5d07afec [AppletQuickItem] Break from loop when we found a layout
There's no point in going on once we found a layout.

REVIEW: 128851
2016-09-06 20:43:54 +02:00
andreas kainz
929f31f555 fix device icon 22px icon didn't work in the old file 2016-09-03 15:41:32 +02:00
David Edmundson
8e517b1578 WindowThumbnail: Do GL calls in the correct thread
WindowThumbnail did some open GL operations, discarding old textures, in
the GUI thread. Whislt it's not going to cause a threading issue (as
updatePaintNode always ran when the main thread was blocked) we're not
meant to mix threads with openGL contexts.

It also seems to have a GL leak on nvidia, which was previously masked
by the double delete fixed in
https://git.reviewboard.kde.org/r/126131/diff/2/
It seems only one worked, and in the applied version we went with the
wrong one.

This patch makes use of QQuickItem::releaseResources to delete the GL
textures on window change and destructor; it's then removed from
stopRedirecting so that start/stop redirecting handles xcb on the GUI
thread and updatePaintNode/discardPixmap is the GL stuff on the render
thread.

See http://doc.qt.io/qt-5/qquickitem.html#graphics-resource-handling

REVIEW: 128763
BUG: 368066
2016-09-03 10:33:44 +02:00
andreas kainz
a4ff82f7f2 add margin and padding to the start.svgz icon
Review: 128800
2016-08-30 15:01:01 +02:00
andreas kainz
cb6c63f961 fix stylesheet stuff in computer icon 2016-08-27 22:21:10 +02:00
andreas kainz
77e0a58a60 Merge branch 'master' of git://anongit.kde.org/plasma-framework 2016-08-26 23:48:08 +02:00
andreas kainz
152b71df5b add computer and laptop icon for kicker
BUG: 367816
2016-08-26 23:47:08 +02:00
David Edmundson
7d0b381061 Fix cannot assign undefined to double warning in DayDelegate
REVIEW: 128765
2016-08-26 12:14:26 +01:00
andreas kainz
532881bd20 fix stylesheed svgz files are not in love with me 2016-08-26 00:12:40 +02:00
andreas kainz
56c08843b4 rename the 22px icons to 22-22-x and the 32px icons to x for kicker 2016-08-25 23:41:18 +02:00
Kai Uwe Broulik
3f17e32a92 [PlasmaComponents TextField] Don't bother loading icons for unused buttons
We kept loading the clear button and reveal password icons even when that option was
disabled and the buttons never visible.

REVIEW: 128753
2016-08-25 22:59:46 +02:00
David Edmundson
81a314c7a9 Extra guard in Containment::corona in the special system tray case
REVIEW: 128754
2016-08-25 17:48:56 +01:00
David Edmundson
22ba8186f0 When marking a containment as deleted, also mark all sub-applets as deleted - fixes system tray container configs not being deleted
This allows a custom applet to do cleanup (like the system tray, to
delete the inner containment)

REVIEW: 128754
2016-08-25 17:48:23 +01:00
Kai Uwe Broulik
7bcd088d7d Fix Device Notifier icon
The icon is device-notifier and not just "device".
Please do not remove or rename icons without review.

CCMAIL: kainz.a@gmail.com
2016-08-25 13:27:55 +02:00
Marco Martin
5c864de1c3 readd window-list
icon was deleted by accident
2016-08-24 11:07:23 +02:00
andreas kainz
b2b980044f add system-search to system in 32 and 22px size 2016-08-23 00:36:49 +02:00
andreas kainz
4162352536 add monochrome icons for kicker
RR: 128721
2016-08-23 00:22:23 +02:00
David Edmundson
417a33544c Set colour scheme on system-search icon 2016-08-22 16:56:53 +01:00
David Edmundson
211147d4dc Move system-search into system.svgz
Otherwise it won't be found.
2016-08-21 22:14:42 +01:00
l10n daemon script
888dca5501 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-08-21 09:22:10 +00:00
Friedrich W. H. Kossebau
6521c72f75 Fix wrong or missing "X-KDE-ParentApp" in desktop file definitions
"X-Plasma-ParentApp" would be nicer, but existing code and desktop files
use "X-KDE-ParentApp" as name for that property

REVIEW: 128616
2016-08-20 17:26:05 +02:00
Friedrich W. H. Kossebau
4bf1ef7ea6 Fix API dox of Plasma::PluginLoader: mixup of applets/dataengine/services/...
REVIEW: 128616
2016-08-20 17:19:14 +02:00
andreas kainz
1370644bac add system-search icon for the sddm theme 2016-08-20 16:15:43 +02:00
andreas kainz
f447c6dacd add nepomuk 32px icon 2016-08-20 16:05:27 +02:00
andreas kainz
8d2109328e update touchpad icon for the system tray 2016-08-20 15:55:51 +02:00
David Edmundson
b07904b901 Remove code that can never be executed.
We know d->uiReady is false, otherwise we wouldn't be in this code
block. Modifying d->loadingApplets won't change that.

REVIEW: 128709
2016-08-18 13:21:08 +01:00
Kai Uwe Broulik
1d66098e50 [ContainmentView] Show panels when UI becomes ready
The code already had logic in there but since UI ready is usually emitted later
the client (in this case plasmashell) had to manually show the panels and would
usually show them when they're not ready yet leading to visual glitches on startup.

REVIEW: 128708
2016-08-18 13:43:29 +02:00
David Edmundson
98cfdf6b45 Don't redeclare property implicitHeight 2016-08-18 12:06:20 +01:00
Marco Martin
f1699fe543 use QQuickViewSharedEngine::setTranslationDomain
setting the domain by just using kdeclarative would lead to
setting the domain on the wrong QQmlContext,
sometimes overwriting it on the global context, causing
unexpected crashes deep in qml
BUG:361513
reviewed-by: Ivan Čukić <ivan.cukic@kde.org>
2016-08-18 12:39:35 +02:00
andreas kainz
5f8f7db226 add 22px and 32px plasma breeze icon support 2016-08-18 00:18:33 +02:00
andreas kainz
76791a1431 22px and 32px plasma breeze icon support available 2016-08-17 23:44:54 +02:00
andreas kainz
4b8642660f remove colored system icons and add 32px monochrome ones
RR: 128598
2016-08-17 23:23:44 +02:00
David Edmundson
cb9ec94625 Add an optional reveal password button to TextField
Similar to KPasswordWidget in kwidgetaddons

Also fixes:
- the clear button still being clickable when not enabled
- RTL icons
- Updating the right margin correctly

REVIEW: 128660
2016-08-15 14:34:15 +01:00
Kai Uwe Broulik
a60f703e09 [DefaultToolTip] Enable LayoutMirroring
This flips the tooltip when using right-to-left languages

CHANGELOG: The standard tooltips are now mirrored when in a right-to-left language

REVIEW: 128662
2016-08-15 13:04:09 +02:00
Kai Uwe Broulik
97a3611c16 [Calendar DaysModel] Don't call layoutChanged() and emit dataChanged() with roles
LayoutChanged causes QML to destroy all delegates and re-create them.
Since the number of days doesn't change but only the numbers, we can just call dataChanged on all roles.

Furthermore, when agenda-related data changes, only the containsEventItems role
might have changed, so only emit a change for it.

CHANGELOG: Performance when changing months in the calendar has been greatly improved

REVIEW: 128648
2016-08-14 11:48:11 +02:00
David Edmundson
920dbcb1e8 Fix missing cleanup in early return
commit c8fdd7ed20 pushes a lazy fix for a
crash, but instead just leaves all signals blocked on
ContainmentInterface

REVIEW: 128642
2016-08-10 10:37:13 +01:00
David Edmundson
1ace6a46de Keep compatiable slot createApplet with Frameworks 5.24
Commit bb70febdbe changed the slot for
adding createApplet, turning the final argument from QPoint to QRect.

If the rectangle size is nothing, it acts like the original code.

Despite this being private API (ish) there is a hacks in plasma-
workspace that call methods on the view via QMetaObject invoke. This
obviously fails. As we need compatibility for Plasma/5.7 and earlier a
compatibility slot needs to stay.

REVIEW: 128640
2016-08-10 00:41:07 +01:00
David Edmundson
8031d80df5 Fix argument type in QMetaObject invoke
Commit bb70febdbe ported an argument from
QRect to QRectF. However, not all local invocations were updated.

REVIEW: 128641
2016-08-10 00:41:07 +01:00
Marco Martin
c8fdd7ed20 crash--
applet may be invalid

Change-Id: I53e831f1fb2dcf991b9248ce79036d77208d5893
2016-08-09 11:41:02 +02:00
David Edmundson
45a2f5a828 Don't delete gl texture twice in thumbnail
The QSGTextures are created with

window()->createTextureFromId(m_texture, QSize(w,h),
QuickWindow::TextureOwnsGLTexture));

this means we don't want to be deleting textures ourselves too, it will
be deleted when we delete the QSGTexture, which is a scoped pointer
inside our QSGNode.

BUG: 355644
BUG: 365946
REVIEW: 126131
2016-08-09 09:37:01 +01:00
David Edmundson
7364377a06 Add translation domain to wallpaper QML object
REVIEW: 128612
2016-08-09 09:37:01 +01:00
Marco Martin
e1a0299a46 don't manually delete applets
applets will be deleted by the parent, as they are
acontainment's children. by not deleting them by hand
also every signal will be disconnected, not causing appletRemoved
to be emitted, so not causing removal of config
pieces at shutdown, this removes the need of the
explicit disconnect in aboutToQuit from contaiment interface

Change-Id: Iddf6ded60ae849ca03c363be6e736da496310b82
reviewed-by: David Edmundson
2016-08-08 15:07:10 +02:00
Aleix Pol
de1a45764a Define what Plasma packagestructures extend plasmashell
It specifies org.kde.plasmashell as the structures' target

REVIEW: 128604
2016-08-05 15:24:23 +02:00
Marco Martin
bb70febdbe support a size for adding applets
in the addapplet signal, support size paramenters as well,
to specify a full geometry where you want the plasmoid.

REVIEW:128597
2016-08-05 10:02:10 +02:00
Aleix Pol
3ba6efa44c Fix build in build.kde.org 2016-08-04 21:26:52 +02:00
Aleix Pol
67d882037c Define Plasma PackageStructure as regular KPackage PackageStructure plugins
This way we can use kpackagetool5 against them (see RR 128590).

REVIEW: 128596
2016-08-04 19:23:59 +02:00
David Edmundson
812340ea2f If we pass a QIcon as an argument to IconItem::Source, use it
Currently the code gets the icon name from the QIcon and tries to do
some Plasma theming with it.
However if that fails it then loads the QIcon::fromTheme again.

This is pointless in most cases and will break any icons that have a
custom loader (all SNIs)

REVIEW: 128580
2016-08-03 12:05:30 +01:00
Chinmoy Ranjan Pradhan
0abc67a99f Add overlay support to Plasma IconItem.
By default Plasma IconItem renders the icon without an overlay even when an overlay is required.
This fixes this.

REVIEW:128573
2016-08-02 22:09:51 +05:30
Eike Hein
433b6794fe Add Qt::Dialog to default flags to make QXcbWindow::isTransient() happy.
Panel popup dialogs along with other applications of Plasma::Dialog
(e.g. Kicker's submenus) currently don't correctly set WM_TRANSIENT_FOR
to the id of their parent window on X11. This causes them to interact
badly with auto-hide panels which do not set struts, e.g. Kicker's
submenus open behind the panel.

Internally, Dialog makes calls to QWindow::setFlags when its window
type is "Normal" (the default) and otherwise uses KWindowSystem's
setType. (Kicker's subclass, SubMenu, does an additional
KWindowSystem::setType call for NET::Menu). Neither CompactApplet
nor Kicker change their Dialog's 'type' property to anything else,
so their dialogs are "Normal", thus going the setFlags route with
no setType calls.

Dialog also sets its transient parent to the window the visualParent
item is inside of.

Now here is where things break down: QXcbWindow will update
WM_TRANSIENT_PARENT for in show(), but only when an inline function
called isTransient returns true. isTransient decides this based on
window type, which is determined from the flags set with
QWindow::setFlags. Calls to KWindowSystem::setType would have no
bearing on this; there seems to be no mapping back from external
state. This is why setting Dialog.type to e.g. "DialogWindow" does
nothing.

This patch takes the route of adding Qt::Dialog to the starting
flags - after all Dialog is a dialog. That means isTransient()
will consider the window to be a transient and those
setTransientParent calls Dialog does will not be ignored. In the
case of CompactApplet, no further calls to KWS::setType are done;
Kicker continues to call it with NET::Menu to get desired window
manager behavior.

In light testing everything still seems too work, with the added
benefit of fixing:
BUG:366278

That said, the weird mess of setFlags and setType and state in the
windowing system vs. Qt is horrible and sad.

REVIEW:128571
2016-08-02 19:20:33 +09:00
Kai Uwe Broulik
009f49c08e [Breeze Plasma Theme] Add network-flightmode-on/off icons
Since nobody bothered to fulfill my request for this icon (cf. Review 128332)
I just did it myself, with no warranty.

Plasma IconItem finds icons from Plasma theme only in the SVG file of the first
section of the name (ie. all icons in network must start with network- prefix
which the flightmode icons did not).

The old icon is kept as is for compatibility.
2016-08-01 17:43:11 +02:00
Eike Hein
98c721e031 Fix build. 2016-08-01 03:57:22 +09:00
Eike Hein
8665999ee7 Emit contextualActionsAboutToShow before showing the applet's contextualActions menu.
This is done by ContainmentInterface::mousePressEvent, but not in this
code path, which is hit for applet panel popups.

Folder View relies on this to update actions ahead of the menu being
opened.

BUG:366294
2016-07-31 21:12:52 +09:00
Kai Uwe Broulik
42193ae631 [TextField] Bind to TextField length instead of text
Copying strings in QML is expensive.

REVIEW: 128550
2016-07-29 15:41:40 +02:00
Kai Uwe Broulik
16f8257068 [Button Styles] Horizontally center in icon-only mode
QtQuick.Layouts by default left aligns content and because the Layout is
anchors.fill'd the icon would show off-center in a button when no text has been set.
This fixes this.

REVIEW: 128493
BUG: 365947
2016-07-26 14:09:03 +02:00
Kai Uwe Broulik
d91127ca58 [Containment] Treat HiddenStatus as low status
The containment's status is the max of all applets.

Unfortunately, HiddenStatus, while semantically lower, has the highest value,
so as soon as there's a hidden applet (eg. pager with just one virtual desktop),
the panel will always auto-hide even when popups are open as its status will be HiddenStatus.

REVIEW: 128301
2016-07-22 08:32:52 +02:00
David Edmundson
3f53070185 Q_INVOKABLE needs to be outside the /// @cond INTERNAL_DOCS 2016-07-20 12:05:12 -03:00
andreas kainz
83f1eb80f3 add kalarm icon for plasma system tray
BUG 362631
2016-07-19 23:17:27 +02:00
Marco Martin
301193cb96 don't assume last is is numScreens()-1
screen ids are going to not be continuous anymore
as screen id is going to correspond 1:1 to connectors,
it will be possible to have "holes", therefore valid ids
that are bigger than screenNum()

REVIEWED-BY:sebas@kde.org
Change-Id: I1c0b1fb827dba4d95f228d32209403150c089c77
2016-07-18 14:47:53 +02:00
andreas kainz
14dc19e1bd update kruler icon 2016-07-16 22:39:53 +02:00
andreas kainz
f0fabfac26 add kruler system tray icon from Yuri Fabirovsky 2016-07-16 22:35:25 +02:00
andreas kainz
bb9c50d25f update wifi networks available icon 2016-07-15 22:11:52 +02:00
Eike Hein
2c6dacea38 Fix the infamous 'dialogs show up on the Task Manager' bug once more.
- Initially set state (and type, and flags) in response to PlatformSurfaceCreated.
  We know reliably this will run before the window is mapped.

- Drop the comment about removing setState() form showEvent handler, as
  we need it to avoid state loss in this scenario:
  <mgraesslin> the window gets mapped first time: everything is fine
  <mgraesslin> window gets unmapped: kwin removes the state as per spec
  <mgraesslin> qt gets change event and removes the states it doesn't care about
  <mgraesslin> qt maps window again and sets states
  <mgraesslin> we lost the state
  <mgraesslin> which means we need to set the state again from our side before(!) Qt sets it
  <mgraesslin> and before Qt maps the window
2016-07-15 19:40:37 +09:00
andreas kainz
b6b26850fd fix network wireless available icon with an ? emblem
BUG: 355490
2016-07-12 19:36:47 +02:00
David Rosca
9070f461bb IconItem: Use better approach to disable animation when going from invisible to visible
Clearing the pixmap is actually wrong, because in some cases the
IconItem::updatePolish() is not called when changing visibility.

REVIEW: 128409
2016-07-12 10:02:47 +02:00
Martin Gräßlin
7f3aa5344a Set Tooltip window type on ToolTipDialog through KWindowSystem API
In order to have support for tooltip window type in Wayland, the
window type NET::Tooltip is also set through KWindowSystem API once
the platform surface is created.

REVIEW: 128300
2016-07-05 08:08:06 +02:00
David Edmundson
fb3e8d5fc5 Make use of QQuickItem::setSize
Even though QQuickItem only has a width and height accessor there is a
usable public setSize method.

This gets rid of a lot of potential re-evaluation as internal geometry
is updated before widthChanged is emitted.

REVIEW: 128316
2016-07-04 11:06:44 +01:00
Kai Uwe Broulik
f24fd0caff [Calendar] Flip arrow buttons on right-to-left languages
This ensures the arrows always point outward, away from the centre button.

REVIEW: 128327
2016-06-30 12:28:09 +02:00
l10n daemon script
19e8f37753 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-06-29 09:34:42 +00:00
andreas kainz
05b346bd69 Merge branch 'master' of git://anongit.kde.org/plasma-framework 2016-06-27 15:13:09 +02:00
andreas kainz
99ce3bab88 add kdeconnect air icon 2016-06-27 15:12:45 +02:00
R. Harish Navnit
eef8c29b7a Plasma::Service::operationDescription() should return a QVariantMap
REVIEW: 127812
2016-06-27 12:11:25 +05:30
David Edmundson
3c1eb48018 Don't include embedded contrainers in containmentAt(pos)
Do to so means the System Tray applet ends up being placed inside the
system tray container, which ends up in a parent loop, causing a stack
overflow every time parent() is called recursively

This happens whenever one drags a sys tray on the desktop or simply adds
a new system tray whilst running.

BUG: 361777

We also need to do a hack for Plasma/5.7 in plasma-desktop somehow in
all cases where this is used.
2016-06-20 21:07:19 +01:00
andreas kainz
c6b35c6b10 fix the color theming for the restart system icon (login screen)
BUG: 364454
2016-06-19 00:11:05 +02:00
Allen Winter
a07c88cf77 plasma/scripting/scriptengine.cpp - -Wunused-parameter 2016-06-15 13:08:39 -04:00
Allen Winter
a04f0c3f8f plasma/private/timetracker.cpp - -Wpedantic 2016-06-15 13:08:39 -04:00
Marco Martin
82222a3ecf fix build
return bool
2016-06-15 16:22:45 +02:00
Marco Martin
9fba7c43c5 disable taskbar thumbnails with llvmpipe
the llvmpipe driver doesn't have a good quality enough for the
taskbar thumbnails components, it will have many crashes in the driver.
disabale thumbnails with that driver, as kwin disables many effects as well.

BUG:363371
2016-06-15 16:01:50 +02:00
Marco Martin
746f57713c guard against invalid applets
an applet can be present but being one that failed to load
therefore with an invalid kplugininfo, which can cause asserts around

BUG:364281
2016-06-15 12:44:04 +02:00
Marco Martin
6f5816fc57 ensure the scriptengine is here
ensure the scriptengine gets created also for c++ applets
that have a valid scriptengine, move the script init
out of applet::init that can be reimplemented.
remove the second appletscript constructor that is
not necessary anymore

REVIEWED-BY: Kai Uwe Broulik
2016-06-15 11:04:21 +02:00
David Faure
967e81611f PluginLoader::loadApplet: restore compatibility for misinstalled applets.
Summary:
The notifications applet installs the .so into the toplevel plugins dir,
and my earlier code removal broke the loading of that applet.

Reviewers: lbeltrame, mart

Reviewed By: mart

Differential Revision: https://phabricator.kde.org/D1851
2016-06-13 22:47:01 +02:00
David Edmundson
4f7ead27d6 Fix null object QObject::connect warning
REVIEW: 128171
2016-06-13 10:58:20 +01:00
Eike Hein
1706b75272 Less debug noise. 2016-06-13 18:38:50 +09:00
David Faure
107c28d361 PluginLoader: improve error message about plugin version compatibility
Summary:
The name of the actual plugin was missing, making the warning rather useless.
Since this is only used within PluginLoader, I added a private function
isPluginVersionCompatible(KPluginLoader), taking code from
Plasma::isPluginVersionCompatible(uint). That one could probably be deprecated,
although no public replacement would be available, just "use PluginLoader".

Test Plan: plasmoidviewer -a org.kde.plasma.digitalclock

Reviewers: mart

Reviewed By: mart

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D1825
2016-06-12 18:13:12 +02:00
David Faure
181869e636 Remove erroneous plugin-loading compat code.
Summary:
This code was passing PREFIX/share/plasma/plasmoids/org.kde.desktopcontainment/metadata.desktop
to KPluginLoader (which expects a .so!), which led to warning noise
"Plasma::isPluginVersionCompatible: unversioned plugin detected, may result in instability"
(since that code tries to find a version symbol in the .so).

The reason why KPluginInfo::libraryPath() returns the .desktop file seems
to be a KPluginMetaData misuse, but this is compat code marked as "to be removed"
so I didn't fully debug the KPluginMetaData misuse.

Test Plan: plasmoidviewer -a org.kde.plasma.digitalclock

Reviewers: mart

Reviewed By: mart

Differential Revision: https://phabricator.kde.org/D1827
2016-06-12 18:12:02 +02:00
David Faure
2a8891ec95 Set the pointer before connecting to it.
This fixes the warning "QObject::connect: invalid null parameter"
2016-06-12 15:54:47 +02:00
David Edmundson
f5ad210742 Fix check to keep QMenu on screen for multiscreen layouts
If x > screenWidth should be if x > screenLeft + screenWidth

otherwise all right hand screens get offset

REVIEW: 128148
2016-06-10 11:57:32 +01:00
Marco Martin
84c29fa3d0 new containment type for the systray
add a new containment type for use in the systray:
this way it will be able to have a screen number without
actually creating a panel from its own

REVIEW:128118
2016-06-07 20:18:06 +02:00
Aleix Pol
9575b8c009 Let Plasma::Corona load the layout on all cases
We either load the existing layout or we load a default one.
With this, it could be removed from ShellCorona.

REVIEW: 127850
2016-06-07 15:23:13 +02:00
andreas kainz
32f3b7b448 add view icon again and fix it 2016-06-03 11:32:56 +02:00
andreas kainz
935916419d update air plasma icons 2016-06-03 02:29:37 +02:00
andreas kainz
d37bf8586c add cantata system tray support
BUG: 363784
2016-06-03 00:10:06 +02:00
Marco Martin
4de0dd2e90 rename state property in status
emergency change: in Qml the name "state" for a property
is reserved for the internal state machine, so any object that
exposes a "state" property on its own would automatically
break the state machine
2016-06-01 14:47:56 +02:00
Marco Martin
f3c05034d9 Selected state for Plasma::Svg and IconItem
Like KIconloader, support a Selected state, in IconItem,
as in all generic svgs/framesvg
it replaces the text color with HighlightedText and the
background color with HighlightColor

Change-Id: Id97a527405d2c3feed75a172f05547defdbf440c
REVIEW:127975
2016-05-31 11:10:47 +02:00
Daniel Vrátil
93905e8c68 DaysModel: reset m_agendaNeedsUpdate when plugin sends new events
Only reset if there's an event for current date. Without that when
the applet tries to get the updated list of events and it gets the
old one (empty) due to the check at the beginning of  eventsForDate().
2016-05-30 01:17:18 +02:00
andreas kainz
a9bcedb94c add system-save-session icon sync with breeze-icons
BUG 356082
2016-05-28 23:54:06 +02:00
andreas kainz
56701aa3c1 update audio and network icon to get a better contrast
BUG: 356082
2016-05-28 23:27:07 +02:00
Allen Winter
97d8cd574c deprecate downloadPath(const QString &file) in favor of downloadPath()
REVIEW: 127870

while I was at it, I make downloadPath() const as suggested by Kai
and fixed 1 spelling error.
2016-05-26 19:09:10 -04:00
Marco Martin
3e55c85167 minimized task always darker
Is important the minimized task always looks "less prominent"
then the other ones, so make it pure black but very translucent
this will make it look always "slightly darker" than the background
is important that task and only that doesn't follow the stylesheet

Change-Id: I9e46dfc1c22b2b0a0d1ece575913fb410213b4c6
2016-05-24 14:33:08 +02:00
Anthony Fieroni
3530cc39d0 [icon thumbnail] Request for preferred icon size
REVIEW: 127826

CCBUG: 362324

Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
2016-05-20 18:59:23 +03:00
Anthony Fieroni
2275db4b39 [dataengine]If the DataEngine constructor is called with an invalid KPluginInfo object, make sure valid is set to false.
+ test case

REVIEW: 127795

Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
2016-05-19 22:45:29 +03:00
Marco Martin
92bad819e7 remove kpart related code
those were the last files licensed LGPL2 only
this code wasn't built or installed so in the end is just
removing dead code
2016-05-19 17:47:09 +02:00
Marco Martin
3bffad8c42 relicense few files
license to LGPL2+ as in frameworks licensing policy
The old license in the files was actually wrong, because:
servicejob_p.h : splitted from servicejob.cpp (already 2+)
in 89b71cd9f195da51993533f7fc2329ddc08a7de4

package_p.h: splitted from package.cpp (already 2+)
in 9cb9cfe65e

packagestructure_p.h: created by me in a629fe4d8f
(by copy/paste of the header)
2016-05-19 17:44:43 +02:00
Kai Uwe Broulik
41e260d886 [AppletInterface] Expose immutability
This allows an applet to query whether widgets are user-locked or
locked down by Kiosk restrictions.

CHANGELOG: Plasmoids can now tell whether widgets are locked by the user or sysadmin restrictions

REVIEW: 127909
2016-05-19 17:12:56 +02:00
Kai Uwe Broulik
f1648148b9 [ContainmentInterface] Don't try to popup empty QMenu
With KIOSK restrictions it can happen that a context menu would be empty.
In this case just a shadow would show up. Do nothing then.

REVIEW: 127947
2016-05-18 19:41:25 +02:00
l10n daemon script
4883c580f9 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-05-18 09:38:52 +00:00
Marco Martin
f98cae5dd0 Use SAX for Plasma::Svg stylesheet replacement
following KIconLoader, use QXmlStreamReader/Writer
here too to replace the svg stylesheet to color
the svg with system colors.
it should be hopefully slightly more efficient

REVIEW:127937
2016-05-17 14:45:54 +02:00
andreas kainz
1c1c52f425 Merge branch 'master' of git://anongit.kde.org/plasma-framework 2016-05-12 01:40:06 +02:00
andreas kainz
7379b9b830 align air icons and add new ones from oxygen-icons 2016-05-12 01:39:25 +02:00
Kai Uwe Broulik
e159643ec4 [DialogShadows] Cache access to QX11Info::display()
It's called several times and even in a loop.

REVIEW: 127893
2016-05-11 19:58:55 +02:00
Marco Martin
e8c5ee60a8 restore air plasma theme icons from KDE4
VDG will do some work on top of it
2016-05-11 11:44:53 +02:00
Kai Uwe Broulik
f78685389a [QuickTheme] Fix properties
Some properties were duplicated (yay moc for not shouting at us), some were
accessing the wrong getter and some were missing.

REVIEW: 127889
2016-05-10 19:16:28 +02:00
Marco Martin
2b7543c343 reload selected color scheme on colors changed 2016-05-10 17:18:48 +02:00
Marco Martin
f0c119696d highlight/highlightedText from proper color group
lately the highlight color of plasma became a very
washed-out blue, (since it switched to use the
global system colors) that was because it actually
taken the highlight color (and highlightedText)
from the wrong source.
there is a correct color group in kcolorscheme for
that, that is Selection, take those two colors
from that (also means highlight and highlightedtext
always be the same in all plasma::theme::colorgroups
but that's not a problem)

update test to reflect that

REVIEW:127842
2016-05-05 12:22:44 +02:00
David Rosca
f336f80039 ConfigModel: Don't try to resolve empty source path from package
ConfigModel may contain ConfigCategory for both QML pages and KCM pages.
The source property will be empty for KCM pages.  This fixes correctly
returning empty source for KCM pages.
Also return the same value from get().

REVIEW: 127702
2016-05-04 17:34:02 +02:00
Martin Klapetek
18af870303 [calendar] Only show the events mark on days grid, not month or year 2016-05-02 19:51:20 -04:00
Allen Winter
f1844014dd declarativeimports/core/windowthumbnail.h - fix -Wreorder warning 2016-05-01 16:02:46 -04:00
l10n daemon script
e2edaa2c1a SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-04-25 10:23:50 +00:00
Wolfgang Bauer
d884119f5a Always write the theme name to plasmarc, also if the default theme is chosen
Currently, the "name" key is deleted from plasmarc when you select the
default theme (breeze) in the desktop theme KCM.
This leads to unexpected behaviour: If you set e.g. oxygen as look&feel,
and then set breeze as desktop theme, Plasma actually uses Air (the
default desktop theme in the oxygen l&f) on next login instead of
breeze. In other words, it is impossible to configure breeze as desktop
theme when using a different look&feel as breeze.

This fixes the problem by removing the check whether the default theme
is selected and always writes the "name" config key to plasmarc.

REVIEW: 127698
2016-04-22 19:23:35 +02:00
Martin Klapetek
08312b2e34 [calendar] Add a mark to days containing an event
REVIEW: 127586
2016-04-20 23:41:23 -04:00
Marco Martin
1cf145861b add Positive, Neutral, Negative text colors
add named colors for positive (usually green)
neutral(usually yellow) negative(usually red)
foreground objects, such as text or parts of
svg icons/themes

REVIEW:127696
Change-Id: I646306339f1684cdc062da3d3af1489af6092372
2016-04-20 18:25:50 +02:00
l10n daemon script
9f1b9e7af5 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-04-19 10:54:27 +00:00
David Rosca
7944fc1d6f ScrollArea: Fix warning when contentItem is not Flickable
REVIEW: 127652
2016-04-15 10:08:43 +02:00
Eike Hein
9bd7e4ce5f Add a prop and method for aligning the menu against a corner of its visual parent.
REVIEW:127646
2016-04-14 22:10:24 +09:00
Eike Hein
17cea8059e Allow setting minimum width on Menu.
REVIEW:127648
2016-04-14 04:21:41 +09:00
Eike Hein
ec16c57e3c Maintain order in stored item list.
Reviewed-by: notmart@gmail.com
2016-04-14 01:38:12 +09:00
Eike Hein
70301e21b9 Extend API to allow (re)positioning menu items during procedural insert.
REVIEW:127645
2016-04-14 01:17:37 +09:00
Marco Martin
553a9bfe53 bind highlightedText color in Plasma::Theme
we have a color in the Plasma theme "highlight" that is basically
an accent color used around.. but one of the uses is to use it as
a background, such as highlighted text. in that case we don't know
what color would be safe for contrasting on top of it for things
like the highlighted text color (plasma style used the background
color for that, which is incorrect)

REVIEW:127637
2016-04-13 12:28:53 +02:00
Friedrich W. H. Kossebau
9f48b41507 Fix unsetting associated application/urls for Plasma::Applets
Summary:
Avoids a crash and a bogus menu entry.

Current code does not properly handle any resetting, which results
in Applet::hasValidAssociatedApplication() still returning true
when urls have been set to an empty list and the application name
to an empty string.
Also are connections to the "destroyed" signal collected on
repeated set calls.
This patch fixes that.

This fixes "Run the Associated Application" menu entry showing up with widgets.

It also prevents the crash in associatedapplicationmanager.cpp:76, which assumes
url lists to be non-empty:
const QString mimeType = mimeDb.mimeTypeForUrl(i.value().first()).name();

Not happy yet with the signal/slot connection management,
improvement proposals welcome.

Reviewers: mart

Reviewed By: mart

Subscribers: plasma-devel

Projects: #plasma

Differential Revision: https://phabricator.kde.org/D1372
2016-04-12 01:09:44 +02:00
Friedrich W. H. Kossebau
d2fdde4002 Don't expose symbols of private class DataEngineManager
Internal class since first release of plasma-frameworks
2016-04-11 14:19:57 +02:00
Marco Martin
1eff0dea81 add an "event" element in the calendar svg
the calendar svg wasn't used anymore in Plasma 5
restore it for markers for events
2016-04-07 20:15:47 +02:00
David Rosca
b3076a410c SortFilterModel: Invalidate filter when changing filter callback
Model is now correctly filtered when setting filter callback.

REVIEW: 127588
2016-04-06 11:02:51 +02:00
Martin Gräßlin
035e061e13 Add nullptr-check for iconTheme
KIconLoader::global()->theme() might return null. Thus we need to
guard for this case (happens e.g. on build.kde.org).

This results in iconThemeMetadataPath not being set, which is fine
as that condition is handled later on.

CCMAIL: notmart@gmail.com
Reviewed-By: Bhushan Shah
2016-04-05 10:06:27 +02:00
Ivan Čukić
8d3ec9589c Properly guarding against a null applet
- The code used applet and d->applet which pointed to the same thing
- Some places checked dereferening of applet, while the last one did not
2016-04-05 09:49:56 +02:00
Ivan Čukić
cdeb168c53 Fixed the logic problem of testing whether the job was valid 2016-04-05 09:33:52 +02:00
Marco Martin
944c7e60dc cache svg icons from icon theme
cache as well svg icons from the icon theme
(invalidating as well when the icon theme is updated)

REVIEW:127260
2016-04-04 17:47:30 +02:00
David Edmundson
ca98250d0c add missing const on private member
REVIEW: 127549
2016-04-03 23:01:23 +01:00
Martin Klapetek
cff18c2cd2 [calendar] Fix calendar applet not clearing selection when hiding
This removes some old cruft that is not really used and serves
basically only as a bool property for checking if it's null and
wheter it equals the last activated date.

This can be done without it by simply resetting the current selected
date (another property) to "today".

REVIEW: 127455
BUG: 360683
2016-03-30 22:53:49 -04:00
andreas kainz
3b7a701c57 update audio icon to use stylesheet 2016-03-29 16:26:48 +02:00
andreas kainz
2480582c0c update audio mute icon
BUG: 360953
2016-03-25 00:36:13 +01:00
Ivan Čukić
8bd9e56572 Fixing the force-creation of applets when plasma is immutable
REVIEW:127442
2016-03-20 22:48:57 +01:00
Kai Uwe Broulik
92e2c07adf [Fading Node] Don't mix opacity separately
This breaks icon item fading when its opacity is smaller than 1 as can be observed
in the "Leave" dialog.

BUG: 355894
REVIEW: 127427
2016-03-20 11:33:07 +01:00
Kai Uwe Broulik
bd354ecf70 [Svg] Don't reparse configuration in response to Theme::applicationPaletteChanged
Plasma::Theme emits the applicationPaletteChanged signal after it has fetched the
colors from KColorScheme and scheduled the caches to be nuked. There's no need to do
the same exact thing from every single Svg out there.

This speeds up Plasma picking up color scheme changes significantly and is now
on a par with other opened applications.

REVIEW: 127426
2016-03-20 11:30:58 +01:00
David Rosca
28b4400da8 Dialog: Set SkipTaskbar/Pager states before showing window
This sets the states before showing the window and is a proper fix
for the linked bug.

Needs e4cea305ed2ba3c9f580bf9d16c59a1048af0e8a from qtbase - Qt 5.6.1

CCBUG: 332024
REVIEW: 127422
2016-03-19 09:02:43 +01:00
Marco Martin
2661cd701c reintroduce busy property in Applet
both the comic and weather applet have to pick out the
_plasma_graphicsObject to access the AppletInterface
object just to set the busy property on it.
this reintroduces the busy proeprty in Applet too,
both setting it to Applet or AppletInterface
will keep them in sync

REVIEW:127411
2016-03-17 18:27:06 +01:00
Aleix Pol
0e9976afb1 Make sure PlasmaQuick export file is properly found
Uses the subdirectories structure as exported by the project.

REVIEW: 127405
2016-03-17 13:33:19 +01:00
Aleix Pol
309c64f5e9 Don't import an nonexistent layout
It should have a containment at least

REVIEW: 127345
2016-03-16 12:33:10 +01:00
Aleix Pol
c23f2415bb Make it possible for an applet to offer a test object
Makes it possible for plasmoids to test themselves in the different shells
by providing API to extract the object that will test the plasmoid
instance.

REVIEW: 127345
2016-03-16 12:32:25 +01:00
David Edmundson
23d020c797 Redo workaround for plasma dialogs flickering
Reviewed-by: David Rosca
2016-03-15 16:48:39 +00:00
David Edmundson
a9c1427eb1 Revert "Fix taskbar flicking when opening Plasma popups"
Causes a problem I missed.
2016-03-15 16:16:14 +00:00
Marco Martin
917b2768a8 org.kde.plasma:force-create in Containment
so much for removing sytray-related hacks.. :/
when the widgets are locked, must be possible to add/remove
widgets in the sytemtray anyways, as their creation/destruction
can depend from dbus activation (or the first time you launch
plasma with the new systray and it must be populated)

Change-Id: I8095ebf831ae57e1306a4d623b253c2a10ef219f
REVIEW:127373
2016-03-15 16:35:13 +01:00
David Edmundson
42e924e7f6 Fix taskbar flicking when opening Plasma popups
When we show a Qt window it resets all wm_states, including the
SKIP_TASKBAR state that Qt doesn't support see
QXcbWindow::setNetWmStates

In order to set the flag we need to do it after Qt has mapped the
window.

This was previously done using ExposeEvent which will happen after show,
but by it being a separate event the task manager will get notified in
the meantime.

By merging into the same event we can make sure the flag is set before
the task manager processes it.

BUG: 332024
REVIEW: 127374
2016-03-15 14:34:20 +00:00
David Rosca
8f6d1f17e4 Replace QMenu::exec with QMenu::popup
REVIEW: 127355
2016-03-12 13:04:39 +01:00
David Rosca
974a2b5071 FrameSvg: Fix dangling pointers in sharedFrames when theme changes
Store theme pointer in FrameData and set it when adding to sharedFrames.

REVIEW: 127344
2016-03-12 13:02:34 +01:00
David Rosca
fd46322300 IconItem: Schedule pixmap update when window changes
QQuickItem::polish is not called when window changes.

Regression from 344d04e230

REVIEW: 127342
2016-03-12 13:01:07 +01:00
David Rosca
46a1181587 IconItem: Animate active and enabled change even with animations disabled
animated: false should disable only animation when changing source,
we still want the hover and enabled animations.
Also fix docs.

REVIEW: 127302
2016-03-11 14:10:59 +01:00
David Rosca
aaa85f3f98 DaysModel: Make update a slot
update is invoked with QMetaMethod, so it must be a slot

Reviewed-by: kbroulik
2016-03-10 16:26:34 +01:00
Kai Uwe Broulik
344d04e230 [Icon Item] Don't animate from previous pixmap when it has been invisible
We have a lot of reusable singletons that are just hidden when not needed, such
as the OSD. IconItem, however, will always fade from the previous state, even if
the previous action happened minutes ago.

This fixes for example changing the volume and then later changing the brightness
where you could see the OSD animating from the volume icon.

REVIEW: 122859
2016-03-10 13:01:29 +01:00
Kai Uwe Broulik
3b115e6d90 [Icon Item] Don't call loadPixmap in setColorGroup
Changing the color group of an Svg emits repaintNeeded which will then
cause it to schedule a pixmap update anyway. Includes a unittest.

REVIEW: 127313
2016-03-10 12:58:18 +01:00
Kai Uwe Broulik
3decfdd869 [Applet] Don't overwrite "Persistent" flag of Undo notification
The setFlags(SkipGrouping) all overwrites the Persistent flag set in the constructor

Reviewed-By: drosca
2016-03-09 18:39:02 +01:00
Marco Martin
e55eb59dbd add two missing categories 2016-03-09 12:44:47 +01:00
Ivan Čukić
63f14f1ddf Allowing to override plasma mutability setting on containment creation
This adds a 'Sledge Hammer'-like flag (trust me I know what I'm doing)
for creating the containment even if the plasma is not set on
'mutable'.
2016-03-09 11:51:38 +01:00
Marco Martin
6973dac801 add icon/titleChanged
make it possible to set icon and title from
the Applet subclass, making appletInterface (so plasmoid obj)
notice about the change and relay the notify signal
2016-03-09 11:34:21 +01:00
David Rosca
d405378219 Remove QtScript dependency
It's not used anywhere.

REVIEW: 127312
2016-03-09 11:29:50 +01:00
Marco Martin
5b0ec83c36 Revert "mechanism for coronas to load plasmoids from custom folders"
This reverts commit 2751b72835.
2016-03-08 15:39:50 +01:00
Marco Martin
12ea79b341 Merge branch 'mart/customShell'
Conflicts:
	examples/CMakeLists.txt
	src/plasma/pluginloader.cpp
2016-03-08 15:38:31 +01:00
l10n daemon script
64a58b210c SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-03-08 10:37:25 +00:00
David Rosca
978b8b3b87 IconItem: Don't overwrite source when using QIcon::name()
source should always return the same value as it was assigned.
Also removed duplicated code (empty sourceString is now handled
as if the source couldn't be converted to any type).

REVIEW: 127282
2016-03-04 23:44:57 +01:00
David Rosca
da340aaefa ContainmentInterface: Fix use of QRect right() and bottom()
right() = x() + width() - 1
bottom() = y() + height() - 1

REVIEW: 127277
2016-03-04 23:44:05 +01:00
Anthony Fieroni
7c06cd064a Merge branch 'master' of git://anongit.kde.org/plasma-framework 2016-03-04 21:06:56 +02:00
Anthony Fieroni
6bb02c88eb [Applet] Don't crash on remove panel
REVIEW: 127240
CCBUG: 345723

Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
2016-03-04 21:06:30 +02:00
l10n daemon script
6464f22534 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-03-04 09:12:16 +00:00
David Edmundson
1b21758570 Remove effectively duplicate code path for handling QPixmaps
IconItem handled both QOixmaps and QImages as a source.

QVariant(somePixmap).canConvert<QImage>() returns true so one of the
two code paths isn't executed. Given converting between the two is
practically free, we don't need two code paths.

REVIEW: 127270
2016-03-04 00:20:56 +00:00
David Edmundson
8c4f789b17 Docs for IconItem
REVIEW: 127268
2016-03-04 00:20:02 +00:00
Marco Martin
58c465c042 fix stylesheet
should fix colors assignments of the scrollbar elements

BUG:359345
2016-03-02 12:14:50 +01:00
l10n daemon script
0f3198644e SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-03-01 11:55:01 +00:00
Eike Hein
ce4f7c1b79 Fix logic. 2016-03-01 17:41:03 +09:00
Eike Hein
3358c9eb9a Don't wipe window mask on every geometry change when compositing is active and no mask has been set.
Avoids an extra full repaint.
2016-03-01 17:27:33 +09:00
David Rosca
60af310cfc Theme: Discard pixmap cache when changing theme
Changing theme also changes color scheme making the pixmap cache
invalid for monochrome icons.

CCBUG: 359924
REVIEW: 127226
2016-03-01 00:06:15 +01:00
David Rosca
30368e1d45 IconItem: Fix changing color of svg icons loaded from icon theme
Connect to repaintNeeded when creating Plasma::Svg.

REVIEW: 127207
2016-02-29 22:28:58 +01:00
Weng Xuetian
066cf0a0d7 Fix svg iconPath resolving in IconItem
This fixes iconPath is not correctly set when its size changes.

REVIEW: 127201
2016-02-29 13:05:48 -08:00
Marco Martin
40b99a9122 if path is passed, pick the tail
PluginLoader::loadApplet works both by passing a simple plugin
name and a full path of a plasmoid package.

However, when loading the optional C++ plugin, we have to look
in the standard plasmoid plugin path, so only consider the
tail of the path name, as is guaranteed that part is equal to
the plugin name.

BUG:359902
Change-Id: Ic7300b7c12d7693bcb5590e29de780109a8ff81c
2016-02-29 17:31:38 +01:00
Marco Martin
f55e20cc5f properties configurationRequired and reason
unbreak api of Applet::SetConfigurationRequired + add bindings to
appletInterface as properties.
new properties configurationRequired and configurationRequiredReason

Change-Id: I18ff01df94c1a0c5fac79ff801bfa76714c9f986
REVIEW:127218
2016-02-29 14:26:52 +01:00
David Edmundson
88ec6de113 Move contextualActionsAboutToShow to Applet
Applet contains the menu actions, therefore reloading the menu should
happen in Applet not AppletInterface. With AppletInterface being a dumb
wrapper.

This exposes functionality to anyone who overrides Applet, but also will
also allows system tray to emit this signal without having to use
private API.

Change-Id: I95e65de315744a78a82ebba2a954e4f3ae1bd7b2
REVIEW: 127217
2016-02-29 12:10:28 +00:00
l10n daemon script
e1e58332e7 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-29 11:17:43 +00:00
Aleix Pol
06c7b9c050 Remove some warnings
Unused variables
Unused code
Unused arguments
Unnecessarily complex code
Initialization order
Duplicated properties

REVIEW: 127214
2016-02-29 00:59:44 +01:00
Aleix Pol
9f62532674 Fix most of Clazy warnings in plasma-framework
REVIEW: 126672
2016-02-29 00:13:41 +01:00
David Rosca
526915895b Add autotests for IconItem
Add some tests for IconItem.
Also found one issue in animation when quickly changing source, first frame
will be rendered with wrong icon.

REVIEW: 127103
2016-02-27 21:24:45 +01:00
l10n daemon script
361204cbee SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-27 09:29:41 +00:00
Marco Martin
d524d96a25 using the margins of the flickable item is wrong
the clip will be at ScrollView, not at flickable level
2016-02-24 12:52:24 +01:00
l10n daemon script
3847dc6d91 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-24 09:12:03 +00:00
David Rosca
172847fc3b DataContainer: Fix slot checks before connect/disconnect
Use indexOfSlot instead of indexOfMethod and check for index >= 0.
Also added missing checks for all dataUpdated connects.

REVIEW: 127133
2016-02-23 19:08:48 +01:00
David Edmundson
73aa13b26d fix uninitialised var
Valgrind pointed this out whilst debugging something else.

REVIEW: 127079
2016-02-23 13:05:10 +00:00
l10n daemon script
78cee23be3 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-22 10:53:01 +00:00
David Rosca
fca765bc05 ToolTip: Prevent multiple geometry changes while changing contents
Unset mainItem and set it back only after changing of tooltip contents
is completed. This improves behavior of morphingpopups effect (popups
animates from/to incorrect values).

REVIEW: 127118
2016-02-21 15:06:44 +01:00
David Rosca
4eeed04f0f Revert "Reparse svgElementsCache instead of deleting it in discardCache"
This reverts commit a8e54e15e1.
2016-02-21 15:05:13 +01:00
l10n daemon script
9e1b7dab46 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-21 09:52:09 +00:00
l10n daemon script
82c351cb04 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-20 09:50:14 +00:00
David Rosca
596fa082dd SvgItem: Don't use Plasma::Theme from rendering thread
Logic is similar to IconItem - rendered image is updated
in updatePolish().

REVIEW: 127115
2016-02-19 18:16:30 +01:00
David Rosca
f4e541ad87 Fix crash from previous commit - nullptr check 2016-02-19 13:39:55 +01:00
David Rosca
a8e54e15e1 Reparse svgElementsCache instead of deleting it in discardCache
svgElementsCache may be created on render thread and deleted
on main thread, which will make KSharedConfig crash because
it uses per-thread storage.

BUG: 359539
REVIEW: 127112
2016-02-19 13:25:26 +01:00
David Rosca
82e172cc9e AppletQuickItem: Fix finding own attached layout
Regression from 344dbeb938

BUG: 358849
REVIEW: 127073
2016-02-19 13:23:26 +01:00
Marco Martin
b6d636cc8f smaller expander for the taskbar
2+ doesn't make sense.
use just a single + in a circle ~half of the old one
2016-02-19 12:44:12 +01:00
l10n daemon script
57fbaa0597 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-19 09:24:58 +00:00
Kai Uwe Broulik
eccf7cf0b2 [ToolTip] Stop show timer if hideTooltip is called
This prevents the tooltip from showing up if hideTooltip was called
before it was shown.

BUG: 358894

Differential Revision: https://phabricator.kde.org/D959
2016-02-18 21:58:35 +01:00
Aleix Pol
978529d175 Remove unused variable
Reviewed by Marco Martin
2016-02-18 17:03:49 +01:00
David Rosca
1f98734dd3 Disable animation of icons in plasma tooltips
Tooltips are now animated with KWin effect.

REVIEW: 126653
2016-02-17 18:40:14 +01:00
Marco Martin
ce9751cb35 drop animations from tooltips
tooltips are now animated by a KWin effect, don't try
to animate own X11 positions, that's quite dangerous

Change-Id: I08ef2bc23ec1ef7cb7c432ba1bf6d9c5b0a0ab01
2016-02-17 17:16:02 +01:00
Marco Martin
3224f87c15 default theme follows color scheme
new breeze-light that is just as the old one

REVIEW:127085

Change-Id: Iab4f79fff172e885f8188e0d1bbf2dea266cb9e3
2016-02-17 12:08:31 +01:00
Dan Vrátil
525bf2d377 Fix IconItem not loading non-theme icons with name
Commit 5184ac introduced a small regression that caused IconItem
to no longer load non-theme icons with name set, for instance icons
coming from sni-qt, causing sni-qt apps to not show in systray.

BUG: 359388
FIXED-IN: 5.20
REVIEW: 127091
2016-02-16 21:16:01 +01:00
David Rosca
4d012a8cc5 Prefer other containments than desktop in containmentAt()
Desktop containment will match every valid pos, so we should
return it only if nothing else matches.

REVIEW: 127075
2016-02-15 19:06:47 +01:00
David Rosca
1e196fdfb2 WindowThumbnail: Discard glx pixmap in stopRedirecting()
BUG: 357895
FIXED-IN: 5.20
REVIEW: 127072
2016-02-15 19:05:26 +01:00
Marco Martin
3ee612c2c7 remove the legacy applets filter
this list was done because some applets broke with
the new shared engine stuff.

since it's many workspace releases ago, unconditionally
use the single engine now.

REVIEW:126918
2016-02-09 11:06:30 +01:00
Kai Uwe Broulik
3c03c950d6 [ToolButtonStyle] Don't rely on an outside ID
If you use Plasma's ToolButtonStyle with different controls than the PlasmaComponents.ToolButton it prints a warning about an ID that does not exist.

Use "control" instead which is guaranteed to be the item.
2016-02-09 11:03:59 +01:00
Marco Martin
1b2c1caf39 don't assume we find a corona
BUG:359026
Change-Id: Idfb18a02f6e1ae35b0b1722c24a784345438003d
2016-02-08 11:59:58 +01:00
Kai Uwe Broulik
4ebf130ee6 [Calendar] Add proper back/forward buttons and a "Today" button
This removes the custom label-based triangles and replaces them with proper ToolButtons
using proper icons. It also adds a "Today" button to return to the current day.
The tooltips on the buttons reflect the actual action ("Previous Month", "Previous Year",
"Previous Decade", depending on the zoom level).

Furthermore, the day names and week numbers now use the regular font size but they're still
visually disconnected. The day names row is hidden in the zoom levels now.

REVIEW: 126960
BUG: 336124
BUG: 348362
BUG: 358536
2016-02-08 00:07:43 +01:00
l10n daemon script
13dc03991d SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-06 09:49:14 +00:00
Marco Martin
8c6f95f2ea add a property separatorVisible
REVIEWED-BY: Kai Uwe Broulik
2016-02-05 16:51:38 +01:00
l10n daemon script
087c10cd43 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-05 09:18:18 +00:00
Marco Martin
4b833d0f4f more explicit removal from m_appletInterfaces
removal should happen in handler of
Containment::AppletDeleted, but make extra sure to remove it
in case removal happens too late and an access happens
in the meantime
make extra sure dead objects aren't in m_appletInterfaces

BUG:358551
2016-02-02 22:43:59 +01:00
Marco Martin
4e03525b47 fix tasks spacing, new tabs 2016-02-02 21:12:05 +01:00
Marco Martin
b6687e507a fix glitches in air and oxygen
* remove custom icons, fallback to breeze (too big hassle maintaining)
* fix taskbar items in air and oxygen (oxygen returning to its original design)
* fix blurbehind mask for oxygen popups
* remove some dead files
2016-02-02 20:26:17 +01:00
l10n daemon script
3dac19023c SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-02-02 10:51:53 +00:00
Marco Martin
8e71d6590b use complementaryColorScheme from KColorScheme
kill many lines of code
2016-01-26 11:47:00 +01:00
l10n daemon script
bd10d78e1e SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-01-22 09:52:02 +00:00
David Rosca
8db7b4f39c Fix document.svgz to use color from stylesheet
Fixed "document-encrypt" and "document-decrypt" icons.

REVIEW: 126812
2016-01-21 15:37:09 +01:00
David Rosca
f688c904a8 AppletQuickItem: Don't try to set initial size bigger than parent size
Trying to set initial size bigger than parent size only results
to item being resized down to fit in parent later.

REVIEW: 126822
BUG: 358200
2016-01-21 15:35:19 +01:00
David Rosca
83cec13edb IconItem: Add usesPlasmaTheme property
Add usesPlasmaTheme (enabled by default) property to make it possible
to disable using icons from Plasma theme.

REVIEW: 126814
2016-01-20 11:28:56 +01:00
Marco Martin
fd9b5bd006 don't load toolbox on types not desktop or panel
exclude customdesktop and custompanel
2016-01-19 23:46:51 +01:00
Kai Uwe Broulik
9e1226f26f [Desktop Themes] Bump version number to match Frameworks version
Please remember to ALWAYS* bump this version number when you do any changes to the SVG files.
Otherwise we won't clear the Plasma theme cache and users end up with a broken theme.
2016-01-19 12:36:54 +01:00
David Rosca
2480dc11fe Fix list.svgz to use color from stylesheet
REVIEW: 126791
2016-01-19 10:31:24 +01:00
David Rosca
5184ac94c9 IconItem: Try to load QIcon::fromTheme icons as svg
When showing QIcons in IconItem, it would ignore stylesheet colors.
This tries to load QIcons created with QIcon::fromTheme as svg, by using
the icon name returned from QIcon::name.

REVIEW: 126792
CCBUG: 353358
2016-01-19 10:14:49 +01:00
David Rosca
11937533e8 Ignore check if just one part of size is zero in compactRepresentationCheck
When debugging the linked bug, it looks like when item's geometry change
eg. from 0x0 to 100x100, geometryChanged may be called twice, first with 100x0
and then finally with 100x100.
This was not issue before, because we used timer to call compactRepresentationCheck.
This changes compactRepresentationCheck so that it early returns also when just
one part of item's size is zero.

Fixes regression from 344dbeb938

REVIEW: 126778
BUG: 358039
2016-01-17 18:02:36 +01:00
Kai Uwe Broulik
d9719f1037 [Units] Return at least 1ms for durations
Animators do not reliably work with a duration of 0 as can be seen in the linked bug report.

Upstream bug report: QTBUG-39766

BUG: 357532
REVIEW: 126652
2016-01-17 12:59:30 +01:00
Kai Uwe Broulik
c4c5e9090a Run currentColorFillFix.sh over tasks.svgz 2016-01-17 12:50:27 +01:00
Kai Uwe Broulik
72910fd448 tasks.svgz: Add "progress" frame
This item will be used to indicate progress (such as download or file copy
progress) in the task bar.

REVIEW: 126719
2016-01-17 12:47:41 +01:00
David Edmundson
d11c7535ba Add clearActions() to remove every applet interface action
REVIEW: 126742
2016-01-16 16:02:57 +00:00