Status: | Work in progress |
---|---|
Proposed branch: | lp:~ricotz/plank/wayland |
Merge into: | lp:plank |
Diff against target: |
275 lines (+65/-22) 9 files modified
lib/DockController.vala (+5/-0) lib/Factories/AbstractMain.vala (+2/-8) lib/HideManager.vala (+18/-8) lib/Items/ApplicationDockItem.vala (+17/-5) lib/Items/ApplicationDockItemProvider.vala (+3/-0) lib/Items/DefaultApplicationDockItemProvider.vala (+7/-1) lib/Items/TransientDockItem.vala (+3/-0) lib/Widgets/CompositedWindow.vala (+4/-0) lib/Widgets/DockWindow.vala (+6/-0) |
To merge this branch: | bzr merge lp:~ricotz/plank/wayland |
Related bugs: | |
Related blueprints: |
Wayland Support
(Medium)
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Docky Core | Pending | ||
Review via email: mp+277344@code.launchpad.net |
Commit message
Description of the change
Just make it run under Wayland nothing more.
* No window management
* Unable to position dock-window
* Broken DND
Wayland doesn't provide a common interface to interact or query information needed for a standalone dock to work, it requires support by the running compositor or even being integrated in it.
- 1443. By Rico Tzschichholz
-
Add methods to check some desktop environment types
- 1444. By Rico Tzschichholz
-
trash: Implement perform_
empty_trash( ) Only try using Nautilus on "GNOME" and "Unity" enviroments
- 1445. By Rico Tzschichholz
-
theme: Add "CascadeHide" option
If true it will cause background and icons to unhide/hide with different
speeds so they will leave/hit the screen-edge at the same time. - 1446. By Rico Tzschichholz
-
po: Update translations
- 1447. By Rico Tzschichholz
-
dragmanager: Don't grab input and abort this drag if DragItem is null
- 1448. By Rico Tzschichholz
-
dockwindow: Be more persuasive to get the window where is should be
- 1449. By Rico Tzschichholz
-
po: Update translations
- 1450. By Rico Tzschichholz
-
Use fixed ObjectClass.
list_properties () of valac 0.31/32 if available - 1451. By Rico Tzschichholz
-
dockitem: Actually use internal constant ITEM_INVALID_
DURATION - 1452. By Rico Tzschichholz
-
po: Make use of "translator-
credits" for Gtk.AboutDialog - 1453. By Rico Tzschichholz
-
po: Update translations
- 1454. By Rico Tzschichholz
-
lib: Add internal compatibility wrapper for gtk+ 3.19.1+
- 1455. By Rico Tzschichholz
-
widgets: Adjust custom widgets for gtk+ 3.19.1+
- 1456. By Rico Tzschichholz
-
theme: Create and use custom Gtk.StyleContext
- 1457. By Rico Tzschichholz
-
dragmanager: Better handling if the actual selection-data is null
- 1458. By Rico Tzschichholz
-
dockitem: Only use file-monitor for "file:/
/"-icon- files - 1459. By Rico Tzschichholz
-
build: Add "run-debug" target for running plank uninstalled within gdb
- 1460. By Rico Tzschichholz
-
lib: Move HoverWindow instance into DockController
- 1461. By Rico Tzschichholz
-
dragmanager: Show descriptive tooltip on external-dnd actions
- 1462. By Rico Tzschichholz
-
dragmanager: desktop-files are special and deserve the drop-to-dock text
- 1463. By Rico Tzschichholz
-
po: Update translations
- 1464. By Rico Tzschichholz
-
po: Update translations
- 1465. By Rico Tzschichholz
-
data: Update appdata to 0.6+ format
- 1466. By Rico Tzschichholz
-
appdata: Make "summary" translatable, re-use tweaked desktop-file comment
- 1467. By Rico Tzschichholz
-
po: Update translations
- 1468. By Rico Tzschichholz
-
Welcome to 2016
- 1469. By Rico Tzschichholz
-
Use clamp() instead of min(max())
- 1470. By Rico Tzschichholz
-
dockpreferences: No need to notify about external changes of DockItems
- 1471. By Rico Tzschichholz
-
dockcontroller: Serialize possible DockItems change on start-up
- 1472. By Rico Tzschichholz
-
dockcontroller: Fix r1471 and actually save DockItems change on start-up
- 1473. By Rico Tzschichholz
-
color: Fix mess-up of r1469
- 1474. By Rico Tzschichholz
-
filedockitem: Hide "Keep in Dock" wile LockItems is enabled
- 1475. By Rico Tzschichholz
-
po: Update translations
- 1476. By Rico Tzschichholz
-
dockrenderer: Don't apply window-scale-factor twice on foreground-
icon-size Regression of r1343
- 1477. By Rico Tzschichholz
-
applicationdock
item: Check LauncherEntry values for actual changes Also restrict the precision of "progress".
- 1478. By Rico Tzschichholz
-
items: Reduce redraw requests on LauncherEntry updates
- 1479. By Rico Tzschichholz
-
items: Fix build without dbusmenu-glib
- 1480. By Rico Tzschichholz
-
unity: Handle bad LauncherAPI clients which have an insane update-rate
Skip/hold requests if they are arriving within a defined threshold of
32ms after the previous one.This avoids plank to freeze while not being able to handle all requests.
- 1481. By Rico Tzschichholz
-
positionmanager: Expand dock on external-drag without enabled zoom too
Also try harder to insert dropped elements at the actually desired spot.
- 1482. By Rico Tzschichholz
-
unity: Allow a specific amount of fast-updates before skipping/delaying
Cope with applications which are firing update-requests for multiple
application-uris at the same time. - 1483. By Rico Tzschichholz
-
Revert "dockpreferences: No need to notify about external changes of DockItems"
This breaks GLib.Settings.
bind() so that DockItems never get saved. - 1484. By Rico Tzschichholz
-
Allow and handle uris with "docklet" scheme
- 1485. By Rico Tzschichholz
-
tests: Drop PreferencesWindow test
- 1486. By Rico Tzschichholz
-
Add some functionality to docklets GUI
Drag'n'drop or double-click a docklet to add it.
- 1487. By Rico Tzschichholz
-
settings: Must take reference of matched ParamSpec
Not doing so results in an undefined behaviour while things ran out of
scope when calling GSettings.bind().This reverts r1430
- 1488. By Rico Tzschichholz
-
build: Fix gtk+-3.0 < 3.10 (non-HiDPI)
- 1489. By Rico Tzschichholz
-
preferenceswindow: Allow changing the backing DockController
- 1490. By Rico Tzschichholz
-
unity: Expose API to handle LauncherEntry DBus clients
- 1491. By Rico Tzschichholz
-
po: Update translations
- 1492. By Rico Tzschichholz
-
Cast callbacks to GLib.SourceFunc where possible
- 1493. By Rico Tzschichholz
-
unity: Use the real sender-name given by NameOwnerChanged
- 1494. By Rico Tzschichholz
-
build: Add autogen.sh to tarball
Conveniently rebuild/update the autotools downstream.
- 1495. By Rico Tzschichholz
-
po: Update translations
- 1496. By Rico Tzschichholz
-
examples: Add UnityClient example
- 1497. By Rico Tzschichholz
-
abstractmain: Use new GLib.Application commandline handling API
Require glib >= 2.40
- 1498. By Rico Tzschichholz
-
build: Drop support for gee-1.0
- 1499. By Rico Tzschichholz
-
build: Drop obsololete glib conditionals and bump vala's target-glib
- 1500. By Rico Tzschichholz
-
build: Drop support for gtk+ < 3.10
- 1501. By Rico Tzschichholz
-
ui: Use valac's gtktemplate support
- 1502. By Rico Tzschichholz
-
po: Update translations
- 1503. By Rico Tzschichholz
-
lib: Update symbols
- 1504. By Rico Tzschichholz
-
build: Only cairo >= 1.13 is required for HiDPI
- 1505. By Rico Tzschichholz
-
tests: Make sure to quit "dock" test application
- 1506. By Rico Tzschichholz
-
preferenceswindow: Keep translated "Preferences" string around for now
- 1507. By Rico Tzschichholz
-
docktheme: Adjust draw-position item-badge to avoid cropped shadow
- 1508. By Rico Tzschichholz
-
positionmanager: Partly restore original icon-zoom
- 1509. By Rico Tzschichholz
-
dockitem: Handle file-monitor event where current launcher was target
If "other" of FileMonitorEven
t.MOVED matches our current launcher-file
than it got replaced by a new file, so avoid doing anything other than
loading possible new information. - 1510. By Rico Tzschichholz
-
items: Handle "PinnedOnly" in DefaultApplicat
ionDockItemProv ider This is more efficient than doing this in the DockController. Only the
actually effected items are created/purged on a settings change. - 1511. By Rico Tzschichholz
-
factories: Generalize "dockitem-file" loader
- 1512. By Rico Tzschichholz
-
items: Add LauncherEntry's transient-items only if allowed
Regression of r1510
- 1513. By Rico Tzschichholz
-
Add "simple and experimental" multi-dock support
Running multiple concurrent instances while using "-n|--name"
is still possible.There are no exposed GUI controls, therefore the newly added
"enabled-docks" settings-key should be used. - 1514. By Rico Tzschichholz
-
items: Add transient-items only if allowed
- 1515. By Rico Tzschichholz
-
Update NEWS
- 1516. By Rico Tzschichholz
-
po: Update translations
- 1517. By Rico Tzschichholz
-
utils: Add internal create_settings() and try_create_
settings( ) ... and make use of them where possible.
- 1518. By Rico Tzschichholz
-
utils: Add internal string_
split_combine( ) - 1519. By Rico Tzschichholz
-
utils: Add internal file_is_dockitem()
- 1520. By Rico Tzschichholz
-
settings: Allow to specify gsetting's bind-flags
- 1521. By Rico Tzschichholz
-
Follow the environment's setting whether to show notifications or not
If false, urgent-bounce and urgent-glow animations are disabled.
- 1522. By Rico Tzschichholz
-
lib: Move DockItemDrawValue and its dependencies to top-level namespace
- 1523. By Rico Tzschichholz
-
docs: Fix build
- 1524. By Rico Tzschichholz
-
controller: If the item-count has changed do a more thorough size-update
- 1525. By Rico Tzschichholz
-
positionmanager: Drop redundant call of update_regions()
- 1526. By Rico Tzschichholz
-
surfacecache: Force allow-downscale if drawing-time is insanely high
If drawing-time of a single surface exceeds a certains limit (30ms) and
"flags" is NONE then set ALLOW_DOWNSCALE to make it less demanding.Also mark the created surface, so the DockRenderer can try to ease things
out for later draw requests. - 1527. By Rico Tzschichholz
-
services: Rename internal Offsettings to EnvironmentSettings
- 1528. By Rico Tzschichholz
-
Check existence of keys in 3rd-party GSchemas before using them
Accessing a non-existing key is a fatal error for GSettings.
- 1529. By Rico Tzschichholz
-
po: Update translations
- 1530. By Rico Tzschichholz
-
prefs: Add TooltipsEnabled setting
This controls whether to show tooltips on hovering items with the cursor.
Tooltips showing up to descibe ongoing DnD-actions are not impacted.It is enabled by default.
- 1531. By Rico Tzschichholz
-
hidemanager: TOUCHPAD devices are able to perform pressure on a barrier
- 1532. By Rico Tzschichholz
-
preferenceswindow: Hide "auto-pinning" setting
- 1533. By Rico Tzschichholz
-
preferenceswindow: Hide "show-dock-item" setting
Make "show-dock-item" default to false
- 1534. By Rico Tzschichholz
-
data: Some tweaking of the default themes
- 1535. By Rico Tzschichholz
-
Update README
- 1536. By Rico Tzschichholz
-
Update NEWS
- 1537. By Rico Tzschichholz
-
Prepare 0.11.0 release
- 1538. By Rico Tzschichholz
-
Back to development
- 1539. By Rico Tzschichholz
-
system: Use DesktopAppInfo.
from_filename( ) to set desktop-filename If the filename property is not set then an empty string will be send out
via org.gtk.gio.DesktopAppI nfo rather than the proper desktop-filename
that we actually have. This is used for startup-notifications by Bamf. - 1540. By Rico Tzschichholz
-
po: Update translations
- 1541. By Rico Tzschichholz
-
dockletmanager: Only handle properly named docklet-libraries
- 1542. By Rico Tzschichholz
-
controller: Actually emmit elements_changed() to make DBusClient work
- 1543. By Rico Tzschichholz
-
vapi: Sync libbamf3.vapi with 0.5.3~bzr0+
16.04.20160322. 1-0ubuntu1 - 1544. By Rico Tzschichholz
-
applicationdock
item: Force indicator-update if running-state changed - 1545. By Rico Tzschichholz
-
applicationdock
item: Use child-* signals of Bamf.View The window-* signals are emitted too early and the internal window/xid
caches of Bamf aren't updated yet. - 1546. By Rico Tzschichholz
-
po: Update translations
- 1547. By Rico Tzschichholz
-
Prepare 0.11.1 release
- 1548. By Rico Tzschichholz
-
Back to development
- 1549. By Rico Tzschichholz
-
lib: Update symbols
- 1550. By Rico Tzschichholz
-
surface: Some minor cleaning
- 1551. By Rico Tzschichholz
-
drawing/color: Add support for HSL and some convenience functions
- 1552. By Rico Tzschichholz
-
clippy: Pass correct index in menu-item-callback
- 1553. By Rico Tzschichholz
-
clippy: text parameter of ClipboardTextRe
ceivedFunc is allowed to be null - 1554. By Rico Tzschichholz
-
po: Update translations
- 1555. By Rico Tzschichholz
-
clippy: Need to own the clipboard's content before allowed to clear it
- 1556. By Rico Tzschichholz
-
po: Update translations
- 1557. By Rico Tzschichholz
-
build: Require valac >= 0.26.0 and drop obsolete conditionals
- 1558. By Rico Tzschichholz
-
lib: Use vala's Cairo.Surface.
get/set_ device_ scale() bindings - 1559. By Rico Tzschichholz
-
vapi: Drop internal copy of x11.vapi
- 1560. By Rico Tzschichholz
-
lib: Add and enforce some file-count limits
This is just a safe-guard to prevent plank from "blowing up" if we are
about to handle an unreasonable amount of files. - 1561. By Rico Tzschichholz
-
docklets: Fill in some descriptions and not leave them blank
- 1562. By Rico Tzschichholz
-
Prepare 0.11.2 release
- 1563. By Rico Tzschichholz
-
Back to development
- 1564. By Rico Tzschichholz
-
po: Update translations
- 1565. By Rico Tzschichholz
-
Add CPUMonitor docklet
- 1566. By Rico Tzschichholz
-
po: Update translations
- 1567. By Rico Tzschichholz
-
appdata: Add some keywords and translate-url
- 1568. By Rico Tzschichholz
-
tests: Fix type mismatch
- 1569. By Rico Tzschichholz
-
clippy: Move generic-typed field initializer to construct
- 1570. By Rico Tzschichholz
-
po: Update translations
- 1571. By Rico Tzschichholz
-
surfacecache: Never clear the cache completely
- 1572. By Rico Tzschichholz
-
po: Update translations
- 1573. By Rico Tzschichholz
-
Make use of vala's native Regex support where possible
- 1574. By Rico Tzschichholz
-
WIP Wayland
Unmerged revisions
- 1574. By Rico Tzschichholz
-
WIP Wayland
Preview Diff
1 | === modified file 'lib/DockController.vala' |
2 | --- lib/DockController.vala 2016-03-23 19:51:11 +0000 |
3 | +++ lib/DockController.vala 2016-11-03 14:10:56 +0000 |
4 | @@ -83,6 +83,11 @@ |
5 | |
6 | construct |
7 | { |
8 | + //FIXME Use some fixed settings for wayland session |
9 | + if (environment_is_session_type (XdgSessionType.WAYLAND)) { |
10 | + prefs.Position = Gtk.PositionType.LEFT; |
11 | + } |
12 | + |
13 | launchers_folder = config_folder.get_child ("launchers"); |
14 | Factory.item_factory.launchers_dir = launchers_folder; |
15 | |
16 | |
17 | === modified file 'lib/Factories/AbstractMain.vala' |
18 | --- lib/Factories/AbstractMain.vala 2016-02-25 14:17:32 +0000 |
19 | +++ lib/Factories/AbstractMain.vala 2016-11-03 14:10:56 +0000 |
20 | @@ -252,15 +252,9 @@ |
21 | internal_quarks_initialize (); |
22 | environment_initialize (); |
23 | |
24 | - // Make sure we are not doing silly things like trying to run in a wayland-session! |
25 | - if (!environment_is_session_type (XdgSessionType.X11)) { |
26 | - critical ("Only X11 environments are supported."); |
27 | - quit (); |
28 | - return; |
29 | - } |
30 | - |
31 | Paths.initialize (exec_name, build_pkg_data_dir); |
32 | - WindowControl.initialize (); |
33 | + if (environment_is_session_type (XdgSessionType.X11)) |
34 | + WindowControl.initialize (); |
35 | DockletManager.get_default ().load_docklets (); |
36 | |
37 | initialize (); |
38 | |
39 | === modified file 'lib/HideManager.vala' |
40 | --- lib/HideManager.vala 2016-03-08 22:15:30 +0000 |
41 | +++ lib/HideManager.vala 2016-11-03 14:10:56 +0000 |
42 | @@ -135,15 +135,22 @@ |
43 | requires (controller.window != null) |
44 | { |
45 | unowned DockWindow window = controller.window; |
46 | - unowned Wnck.Screen wnck_screen = Wnck.Screen.get_default (); |
47 | - |
48 | -#if HAVE_BARRIERS |
49 | - initialize_barriers_support (); |
50 | -#endif |
51 | |
52 | window.enter_notify_event.connect (handle_enter_notify_event); |
53 | window.leave_notify_event.connect (handle_leave_notify_event); |
54 | |
55 | + //FIXME Startup fixes for wayland session |
56 | + if (environment_is_session_type (XdgSessionType.WAYLAND)) { |
57 | + Hidden = false; |
58 | + Hovered = true; |
59 | + return; |
60 | + } |
61 | + |
62 | +#if HAVE_BARRIERS |
63 | + initialize_barriers_support (); |
64 | +#endif |
65 | + |
66 | + unowned Wnck.Screen wnck_screen = Wnck.Screen.get_default (); |
67 | wnck_screen.window_opened.connect_after (schedule_update); |
68 | wnck_screen.window_closed.connect_after (schedule_update); |
69 | wnck_screen.active_window_changed.connect_after (handle_active_window_changed); |
70 | @@ -156,20 +163,23 @@ |
71 | { |
72 | unowned DockWindow window = controller.window; |
73 | unowned DragManager drag_manager = controller.drag_manager; |
74 | - unowned Wnck.Screen wnck_screen = Wnck.Screen.get_default (); |
75 | |
76 | controller.prefs.notify.disconnect (prefs_changed); |
77 | |
78 | window.enter_notify_event.disconnect (handle_enter_notify_event); |
79 | window.leave_notify_event.disconnect (handle_leave_notify_event); |
80 | |
81 | + stop_timers (); |
82 | + |
83 | + if (!environment_is_session_type (XdgSessionType.X11)) |
84 | + return; |
85 | + |
86 | + unowned Wnck.Screen wnck_screen = Wnck.Screen.get_default (); |
87 | wnck_screen.window_opened.disconnect (schedule_update); |
88 | wnck_screen.window_closed.disconnect (schedule_update); |
89 | wnck_screen.active_window_changed.disconnect (handle_active_window_changed); |
90 | wnck_screen.active_workspace_changed.disconnect (handle_workspace_changed); |
91 | |
92 | - stop_timers (); |
93 | - |
94 | #if HAVE_BARRIERS |
95 | gdk_window_remove_filter (null, (Gdk.FilterFunc)xevent_filter); |
96 | |
97 | |
98 | === modified file 'lib/Items/ApplicationDockItem.vala' |
99 | --- lib/Items/ApplicationDockItem.vala 2016-03-29 13:36:06 +0000 |
100 | +++ lib/Items/ApplicationDockItem.vala 2016-11-03 14:10:56 +0000 |
101 | @@ -294,6 +294,9 @@ |
102 | return; |
103 | } |
104 | |
105 | + if (!environment_is_session_type (XdgSessionType.X11)) |
106 | + return; |
107 | + |
108 | var window_count = WindowControl.get_num_windows (App); |
109 | |
110 | if (window_count <= 1) { |
111 | @@ -326,12 +329,15 @@ |
112 | { |
113 | if (!is_window ()) |
114 | if (button == PopupButton.MIDDLE |
115 | - || (button == PopupButton.LEFT && (App == null || WindowControl.get_num_windows (App) == 0 |
116 | + || (button == PopupButton.LEFT && (!is_running () |
117 | || (mod & Gdk.ModifierType.CONTROL_MASK) == Gdk.ModifierType.CONTROL_MASK))) { |
118 | launch (); |
119 | return AnimationType.BOUNCE; |
120 | } |
121 | |
122 | + if (!environment_is_session_type (XdgSessionType.X11)) |
123 | + return AnimationType.NONE; |
124 | + |
125 | if (button == PopupButton.LEFT && App != null && WindowControl.get_num_windows (App) > 0) { |
126 | WindowControl.smart_focus (App, event_time); |
127 | return AnimationType.DARKEN; |
128 | @@ -345,7 +351,7 @@ |
129 | */ |
130 | protected override AnimationType on_scrolled (Gdk.ScrollDirection direction, Gdk.ModifierType mod, uint32 event_time) |
131 | { |
132 | - if (App == null || WindowControl.get_num_windows (App) == 0) |
133 | + if (!is_running ()) |
134 | return AnimationType.NONE; |
135 | |
136 | if (GLib.get_monotonic_time () - LastScrolled < ITEM_SCROLL_DURATION * 1000) |
137 | @@ -353,6 +359,9 @@ |
138 | |
139 | LastScrolled = GLib.get_monotonic_time (); |
140 | |
141 | + if (!environment_is_session_type (XdgSessionType.X11)) |
142 | + return AnimationType.NONE; |
143 | + |
144 | if (direction == Gdk.ScrollDirection.UP || direction == Gdk.ScrollDirection.LEFT) |
145 | WindowControl.focus_previous (App, event_time); |
146 | else |
147 | @@ -421,7 +430,8 @@ |
148 | } |
149 | |
150 | var event_time = Gtk.get_current_event_time (); |
151 | - if (is_running () && window_count > 0) { |
152 | + if (is_running () && window_count > 0 |
153 | + && environment_is_session_type (XdgSessionType.X11)) { |
154 | var item = create_menu_item ((window_count > 1 ? _("_Close All") : _("_Close")), "window-close-symbolic;;window-close"); |
155 | item.activate.connect (() => WindowControl.close_all (App, event_time)); |
156 | items.add (item); |
157 | @@ -468,7 +478,9 @@ |
158 | continue; |
159 | |
160 | Gtk.MenuItem window_item; |
161 | - var pbuf = WindowControl.get_window_icon (window); |
162 | + Gdk.Pixbuf? pbuf = null; |
163 | + if (environment_is_session_type (XdgSessionType.X11)) |
164 | + pbuf = WindowControl.get_window_icon (window); |
165 | var window_name = window.get_name (); |
166 | window_name = shorten_window_name (window_name); |
167 | |
168 | @@ -479,7 +491,7 @@ |
169 | |
170 | if (window.is_active ()) |
171 | window_item.set_sensitive (false); |
172 | - else |
173 | + else if (environment_is_session_type (XdgSessionType.X11)) |
174 | window_item.activate.connect (() => WindowControl.focus_window (window, event_time)); |
175 | |
176 | items.add (window_item); |
177 | |
178 | === modified file 'lib/Items/ApplicationDockItemProvider.vala' |
179 | --- lib/Items/ApplicationDockItemProvider.vala 2016-02-22 18:53:22 +0000 |
180 | +++ lib/Items/ApplicationDockItemProvider.vala 2016-11-03 14:10:56 +0000 |
181 | @@ -195,6 +195,9 @@ |
182 | |
183 | protected virtual void app_opened (Bamf.Application app) |
184 | { |
185 | + if (!environment_is_session_type (XdgSessionType.X11)) |
186 | + return; |
187 | + |
188 | // Make sure internal window-list of Wnck is most up to date |
189 | Wnck.Screen.get_default ().force_update (); |
190 | |
191 | |
192 | === modified file 'lib/Items/DefaultApplicationDockItemProvider.vala' |
193 | --- lib/Items/DefaultApplicationDockItemProvider.vala 2016-02-22 10:55:51 +0000 |
194 | +++ lib/Items/DefaultApplicationDockItemProvider.vala 2016-11-03 14:10:56 +0000 |
195 | @@ -62,7 +62,7 @@ |
196 | { |
197 | Logger.verbose ("DefaultDockItemProvider.update_visible_items ()"); |
198 | |
199 | - if (Prefs.CurrentWorkspaceOnly) { |
200 | + if (environment_is_session_type (XdgSessionType.X11) && Prefs.CurrentWorkspaceOnly) { |
201 | unowned Wnck.Workspace? active_workspace = Wnck.Screen.get_default ().get_active_workspace (); |
202 | foreach (var item in internal_elements) { |
203 | unowned TransientDockItem? transient = (item as TransientDockItem); |
204 | @@ -121,6 +121,9 @@ |
205 | |
206 | void connect_wnck () |
207 | { |
208 | + if (!environment_is_session_type (XdgSessionType.X11)) |
209 | + return; |
210 | + |
211 | unowned Wnck.Screen screen = Wnck.Screen.get_default (); |
212 | |
213 | screen.active_window_changed.connect_after (handle_window_changed); |
214 | @@ -130,6 +133,9 @@ |
215 | |
216 | void disconnect_wnck () |
217 | { |
218 | + if (!environment_is_session_type (XdgSessionType.X11)) |
219 | + return; |
220 | + |
221 | unowned Wnck.Screen screen = Wnck.Screen.get_default (); |
222 | |
223 | screen.active_window_changed.disconnect (handle_window_changed); |
224 | |
225 | === modified file 'lib/Items/TransientDockItem.vala' |
226 | --- lib/Items/TransientDockItem.vala 2015-11-03 10:37:19 +0000 |
227 | +++ lib/Items/TransientDockItem.vala 2016-11-03 14:10:56 +0000 |
228 | @@ -69,6 +69,9 @@ |
229 | |
230 | void update_forced_pixbuf () |
231 | { |
232 | + if (!environment_is_session_type (XdgSessionType.X11)) |
233 | + return; |
234 | + |
235 | if (delayed_update_timer_id > 0U) |
236 | return; |
237 | |
238 | |
239 | === modified file 'lib/Widgets/CompositedWindow.vala' |
240 | --- lib/Widgets/CompositedWindow.vala 2015-11-03 10:37:19 +0000 |
241 | +++ lib/Widgets/CompositedWindow.vala 2016-11-03 14:10:56 +0000 |
242 | @@ -40,6 +40,10 @@ |
243 | app_paintable = true; |
244 | decorated = false; |
245 | resizable = false; |
246 | + |
247 | + if (!environment_is_session_type (XdgSessionType.X11)) |
248 | + return; |
249 | + |
250 | double_buffered = false; |
251 | |
252 | unowned Gdk.Screen screen = get_screen (); |
253 | |
254 | === modified file 'lib/Widgets/DockWindow.vala' |
255 | --- lib/Widgets/DockWindow.vala 2016-03-04 15:54:48 +0000 |
256 | +++ lib/Widgets/DockWindow.vala 2016-11-03 14:10:56 +0000 |
257 | @@ -536,6 +536,9 @@ |
258 | */ |
259 | public void update_icon_regions () |
260 | { |
261 | + if (!environment_is_session_type (XdgSessionType.X11)) |
262 | + return; |
263 | + |
264 | Logger.verbose ("DockWindow.update_icon_regions ()"); |
265 | |
266 | var use_hidden_region = (menu_is_visible () || controller.hide_manager.Hidden); |
267 | @@ -557,6 +560,9 @@ |
268 | */ |
269 | public void update_icon_region (ApplicationDockItem appitem) |
270 | { |
271 | + if (!environment_is_session_type (XdgSessionType.X11)) |
272 | + return; |
273 | + |
274 | if (!appitem.is_running ()) |
275 | return; |
276 |