Commit Graph

388 Commits (bc236f3a4d6615288888689f9d73e083fab3b0de)

Author SHA1 Message Date
Martin Gräßlin bc236f3a4d [aurorae] Improve reading the border elements from C++ side
The KWin::Borders element is provided by an extension plugin. The reason
for that is to be able to use it from e.g. the kcm or Plasmate without
needing to compile the code in.

But this results in Aurorae itself not being able to access the element.
The solution is to first load our decoration plugin and afterwards
register the borders element again with the version compiled in from
Aurorae.

With that we can now read all borders and paddings without using
properties. Also we could connect to change signals and have the borders
and padding handling completely stateful. Might be an idea for extending
the decoration library...
2014-06-23 08:08:36 +02:00
Martin Gräßlin b85984fe8e [aurorae] Recreate decoration on config change
Border size might have changed and because of that we need to recreate
the decoration.
2014-06-23 07:42:18 +02:00
Martin Gräßlin 500ff7f68c [clients/aurorae] Change some connects to new syntax 2014-06-16 11:37:48 +02:00
Martin Gräßlin d0c83ddbf3 [kcmkwin/deco] Support loading translations for UI loaded configs
Qml based Aurorae themes can provided a ui file which gets loaded at
runtime. Obviously such a ui file is not translated. This introduces
quite a hack to load the translated strings.

First of all a new property is added to the service file for
specifying the translation domain to be used for the config UI. If
such a translation domain is set we extract all string properties of
the loaded UI and pass them through ki18nd.
2014-06-10 15:49:19 +02:00
l10n daemon script e73f6b2278 SVN_SILENT made messages (.desktop file) 2014-06-10 10:37:36 +00:00
Martin Gräßlin 48c3519390 [aurorae] Reparent main item to the QQuickWindow
This hopefully works around QTBUG-39336.

BUG: 335253
REVIEW: 118416
2014-06-03 09:20:53 +02:00
l10n daemon script 7553c411c2 SVN_SILENT made messages (.desktop file) 2014-05-03 08:32:58 +00:00
l10n daemon script 2f28437e24 SVN_SILENT made messages (.desktop file) 2014-05-02 08:51:14 +00:00
l10n daemon script 2838a9b606 SVN_SILENT made messages (.desktop file) 2014-04-29 10:12:33 +00:00
l10n daemon script 15aa971aab SVN_SILENT made messages (.desktop file) 2014-04-29 04:54:44 +00:00
l10n daemon script e1f418f4d0 SVN_SILENT made messages (.desktop file) 2014-04-28 09:00:35 +00:00
l10n daemon script f44575ddbf SVN_SILENT made messages (.desktop file) 2014-04-28 05:16:52 +00:00
l10n daemon script 69c3289c18 SVN_SILENT made messages (.desktop file) 2014-04-27 21:02:43 +00:00
l10n daemon script e6db000065 SVN_SILENT made messages (.desktop file) 2014-04-04 05:29:27 +00:00
l10n daemon script eef56c98b2 SVN_SILENT made messages (.desktop file) 2014-04-03 05:10:09 +00:00
David Faure 20bc3ff68b Include ksharedconfig.h (since it will be removed from kpluginfactory.h) 2014-03-29 09:32:06 +01:00
Martin Gräßlin cdd9c5bcf5 [kwin/aurorae] Have the QMutex in the Factory and not in each Client
This seems to fix the crash which could happen when closing a window. At
least the kwindowsystem unit tests no longer crash KWin (it was very
reliable before).

BUG: 332091
2014-03-27 14:19:04 +01:00
Marco Martin 16253d7fc3 qtextracomponents->kquickcontrolsaddons 2014-03-25 17:13:43 +01:00
Martin Gräßlin cf45bf43a6 [kwin/aurorae] Remove kde4 support bits from CMakeLists.txt 2014-03-18 10:56:46 +01:00
Aleix Pol c72e519d9c Remove KDE/ prefix in include directories
It's unneeded and deprecated since KF5.
2014-03-17 16:24:10 +01:00
Martin Gräßlin 5f6fcbbc9e [kwin/aurorae] Removed unused KPluginInfo
Removes warning about deprecated functionality.
2014-03-17 09:34:45 +01:00
Martin Gräßlin f74df28450 [kwin] Use KPluginTrader and json metadata to find KDecorations
* A KDecoration needs to include json metadata
* A KDecoration needs to be installed to kwin/kdecorations
* Aurorae and Oxygen adjusted
* kcmdeco locates all decorations through the KPluginTrader
* libkdecoration uses KPluginTrader to find the plugin
* config plugins also need to include json metadata with
  X-KDE-PluginInfo-Name being the same as the decoration
* config plugins need to get installed to kwin/kdecorations/config
* kcmdeco locates the config plugin for a deco through the name
  and KPluginTrader

REVIEW: 116765
2014-03-17 07:41:14 +01:00
l10n daemon script 4d9c6af719 SVN_SILENT made messages (.desktop file) 2014-03-14 07:37:21 +00:00
Martin Gräßlin 4703339ef6 [kwin/aurorae] Remove behavior animations on anchors
Looks like this completely broke in Qt. The groups are all placed at
0/0 if there is an animation defined and the complete layout is broken.

The animation is not that useful in fact so no big loss.
2014-03-12 11:45:46 +01:00
Martin Gräßlin 9fc3aabc66 [kwin/aurorae] Default to no close on double click menu button
To increase consistency with other decorations and because it changes
the behavior of the menu button in an unexpected way we default to
double click menu button doesn't close the window.

BUG: 331462
FIXED-IN: 5.0
REVIEW: 116716
2014-03-11 15:46:21 +01:00
Martin Gräßlin b3d3c45149 Use KPluginLoader to load our decoration plugins
This simplifies the plugin loading. Decorations just have to use
K_PLUGIN_FACTORY to specify how the KDecorationFactory needs to be
created. The KWIN_DECORATION macro is adjusted to generate the
boiler plate code, but it now needs to specify the name for the
pluginfactory and the KDecorationFactory.

This also transits the decoration abi version check to use
K_EXPORT_PLUGIN_VERSION which also simplifies the loading.

As a result the complete canLoad handling in DecorationPlugins is
removed.

REVIEW: 115930
2014-03-03 13:55:52 +01:00
Matteo De Carlo 8b5e4bfcfe Replace NULL with nullptr in clients folder
Replacing all NULL to nullptr in all the files in clients folder
(also substituting some "0" used as nullptr with nullptr)

REVIEW: 115921
2014-02-24 17:02:11 +01:00
l10n daemon script 6f8c3dd771 SVN_SILENT made messages (.desktop file) 2014-02-18 05:12:30 +00:00
Martin Gräßlin a6c47e0314 [kwin] Add ProvidersUrl to *.knsrc
That at least inits the GHNS download dialog.
2014-02-03 13:04:12 +01:00
l10n daemon script 22a5e1109f SVN_SILENT made messages (.desktop file) 2014-01-19 04:06:03 +00:00
Aleix Pol e995a9d76f Remove qt4_automoc calls
They're not needed anymore, and break my build directory from time to time.
If this commit breaks your compilation, clean your build directory (or at
least the plasma and kwin subdirectories).
2014-01-07 15:29:44 +01:00
Martin Klapetek 54bc491c46 Port to KF5 renaming changes 2013-12-11 21:41:47 +01:00
Jacob Logan 199ed87c61 [libkdecorations] Generate an export header
REVIEW: 114247
2013-12-05 10:00:46 +01:00
Eric Newberry 02a42b355b Converted Aurorae to categorized logging. 2013-11-25 15:37:33 +01:00
Martin Gräßlin 719923d410 [kwin/aurorae] Add mutex locker around access to the render buffer
We were facing crashes when the buffer image was being read from and
written to at the same time.
2013-11-14 09:41:52 +01:00
Martin Gräßlin 73e0a6586c [aurorae] Use enum type for Decoration Buttons
Defines the DecorationButton type in DecorationOptions (needs to be
re-defined due to QML limitations) and exports the buttons as a
QList<int> property (again QML limitations).

All QML files are switched from string to the new enum type.
2013-11-14 09:41:52 +01:00
Martin Gräßlin 529fcf0c46 [aurorae] Drop default title buttons left/right from theme config
Nowhere used inside Aurorae.
2013-11-14 09:41:52 +01:00
Martin Gräßlin 612709d9d3 [aurorae] Use QWindow based API instead of wrapping in a QWidget
Works quite decently already, but some things do not work properly yet,
e.g. doubleclick on decoration is not noticed.
2013-11-14 09:41:51 +01:00
Martin Gräßlin 98549449d6 [aurorae] Implement new render method in Aurorae
Improves the situation a little bit: schedules updates without
rendering to the QWidget, but still fbo -> QImage in each frame.
2013-11-14 09:41:50 +01:00
Martin Gräßlin f8acfbf2a0 [aurorae] Connect PlastikButton to options::colorChanged signal
Fixes incorrect button color. DecorationOptions and PlastikButton are
both connected to decoration.active and the button gets invoked first,
thus the titleBarColor is still for the previous state. This was fun!
2013-11-14 09:41:50 +01:00
Martin Gräßlin dd6598c1ff [aurorae] Hack to get Aurorae work with compositing
This is a temporary solution! A proper solution needs changes in
libkdecoration and paint redirector.

The hack redirects the rendering into an FBO. After each rendering we
get a QImage from the FBO and store that in a buffer. As we unfortunately
do not know what changed, we schedule a complete update on the deco's
widget. Once we get the paint event we just render the buffer on the
widget. And thus we have copied the content to a place where it
integrates with the paint redirector.

As already written, this is a horrible hack and I'm not proud about it.
There are just too many copies involved.

So how to improve?
* deco should be able to just provide a QImage to the PaintRedirector
  without the paint to the QWidget.
* only do the FBO -> QImage step if it is needed by the compositor, that
  is compress the events
* for OpenGL compositing it would be totally awesome if we could just
  make the contexts sharing so that we can just reuse the texture from
  the FBO directly.
2013-11-14 09:41:50 +01:00
Martin Gräßlin 93c2eea528 [aurorae] Use QtQuick2 instead of QtDeclarative
Major transition to render using QtQuick 2. This means the actual
rendering needs a QQuickWindow which we embed into a QWidget container.
Not an optimal solution, deco API should offer to operate on QWindow.

For non-composited the decoration gets rendered but for composited
rendering the paint redirector is broken. There are no paint events on
the main QWidget to intercept and thus the redirection doesn't work.
2013-11-14 09:41:50 +01:00
Martin Gräßlin d1afcc7cb2 [aurorae] Whether animations are supported only depends on compositing
Test for raster graphics system doesn't make any sense in QtQuick2 world.
2013-11-14 09:41:50 +01:00
Martin Gräßlin 736a0c5611 [aurorae] Fix locating of theme configuration file 2013-11-14 09:41:50 +01:00
Raphael Kubo da Costa 54b08b9d9e Merge branch 'KDE/4.11'
* KDE/4.11:
  Remove assertion in KDecorationUnstable's constructor.
  SVN_SILENT made messages (.desktop file)
  Cursor Theme KCM: Show correct resize cursor in preview for themes without a file called "size_fdiag"
  Fixed missing signal/slot connection:
  Fix zoom effect cursor position on initial zoom in.
  SVN_SILENT made messages (.desktop file)
  Don't show borders for a maximized Laptop client
  Always use PositionCenter for maximized windows
  Fix click on trash plasmoid when on desktop and widgets are unlocked

Conflicts:
	kwin/clients/aurorae/src/aurorae.cpp
	kwin/libkdecorations/kdecoration.cpp
	plasma/desktop/applets/trash/trash.cpp
	plasma/desktop/toolboxes/plasma-toolbox-desktoptoolbox.desktop
	plasma/desktop/toolboxes/plasma-toolbox-paneltoolbox.desktop
	plasma/generic/wallpapers/color/plasma-wallpaper-color.desktop
	plasma/generic/wallpapers/image/plasma-wallpaper-image.desktop
2013-10-20 17:42:39 +03:00
Sebastian Kügler b68867463e Change KF5::plasma to KF5::Plasma
Library name has changed in plasma-framework to bring it in line with
KF5:CamelCasing naming.
2013-10-16 01:36:56 +02:00
Sebastian Kügler 3ec1b9fd6a link against Plasma, it's using framesvg 2013-10-11 01:10:11 +02:00
Sebastian Kügler b8c55eddc5 Try to make jenkins happy
The logic to use $INCLUDE_INSTALL_DIR/KDE doesn't work there, since the
plasma includes land in a different path on the jenkins setup. Let's see
if this fixes it.
2013-10-11 01:00:31 +02:00
Martin Gräßlin 0ec8646d78 Always use PositionCenter for maximized windows
It was showing the resize cursor at the top title edge which is not
wanted in maximized mode.
2013-10-08 10:15:08 +02:00
Martin Gräßlin 8055cde910 [aurorae] Plastik theme transits to QtQuick 2 2013-10-01 14:05:58 +02:00