Added phosh
This commit is contained in:
26
gui-wm/phosh/files/0002-only-lock-when-not-near.patch
Normal file
26
gui-wm/phosh/files/0002-only-lock-when-not-near.patch
Normal file
@@ -0,0 +1,26 @@
|
||||
diff --git a/src/shell.c b/src/shell.c
|
||||
index 324b261..4a66866 100644
|
||||
--- a/src/shell.c
|
||||
+++ b/src/shell.c
|
||||
@@ -535,15 +535,18 @@ static void
|
||||
on_builtin_monitor_power_mode_changed (PhoshShell *self, GParamSpec *pspec, PhoshMonitor *monitor)
|
||||
{
|
||||
PhoshMonitorPowerSaveMode mode;
|
||||
+ PhoshSensorProxyManager *sensor_proxy_manager;
|
||||
+ gboolean near;
|
||||
+
|
||||
+ near = phosh_dbus_sensor_proxy_get_proximity_near (
|
||||
+ PHOSH_DBUS_SENSOR_PROXY (sensor_proxy_manager));
|
||||
|
||||
g_return_if_fail (PHOSH_IS_SHELL (self));
|
||||
g_return_if_fail (PHOSH_IS_MONITOR (monitor));
|
||||
|
||||
g_object_get (monitor, "power-mode", &mode, NULL);
|
||||
-#if 0
|
||||
- if (mode == PHOSH_MONITOR_POWER_SAVE_MODE_OFF)
|
||||
+ if (!near && mode == PHOSH_MONITOR_POWER_SAVE_MODE_OFF)
|
||||
phosh_shell_lock (self);
|
||||
-#endif
|
||||
|
||||
phosh_shell_set_state (self, PHOSH_STATE_BLANKED, mode == PHOSH_MONITOR_POWER_SAVE_MODE_OFF);
|
||||
}
|
||||
Reference in New Issue
Block a user