forked from enlightenment/enlightenment
blanking - special timeout immediately and force dpms todo
make special timeout universal and in all cases. cleaner with better power management as we turn off bakclights earlier in some cases etc.
This commit is contained in:
parent
14a30c74b0
commit
d961e31436
2
TODO
2
TODO
|
@ -77,8 +77,6 @@ TODO:
|
|||
* massive lowering of barrier ro create/change scriptlets
|
||||
* offer a share mechanism like shots?
|
||||
* security issue - they run. verification needed?
|
||||
* fix lock screen to force dpms on once it has blanked if special
|
||||
timeout exists
|
||||
* keyboard backlight controls, not just screen
|
||||
* backlight module/controls should control the screen the gadget is on
|
||||
* allow multiple screens to have different backlight controls
|
||||
|
|
|
@ -360,6 +360,7 @@ _desklock_show_internal(Eina_Bool suspend)
|
|||
_e_desklock_state = EINA_TRUE;
|
||||
e_bindings_disabled_set(1);
|
||||
e_screensaver_update();
|
||||
e_dpms_force_update();
|
||||
return 1;
|
||||
lang_fail:
|
||||
if (e_config->desklock_language)
|
||||
|
@ -432,6 +433,7 @@ _desklock_hide_internal(void)
|
|||
ecore_event_add(E_EVENT_DESKLOCK, ev, NULL, NULL);
|
||||
|
||||
e_screensaver_update();
|
||||
e_dpms_force_update();
|
||||
|
||||
if (e_desklock_is_external())
|
||||
{
|
||||
|
|
|
@ -51,18 +51,23 @@ E_API int
|
|||
e_screensaver_timeout_get(Eina_Bool use_idle)
|
||||
{
|
||||
int timeout = 0, count = (1 + _e_screensaver_ask_presentation_count);
|
||||
Eina_Bool use_special_instead_of_dim = EINA_FALSE;
|
||||
|
||||
if (_screensaver_now) return 1;
|
||||
if ((e_config->screensaver_enable) && (!e_config->mode.presentation))
|
||||
{
|
||||
if ((e_desklock_state_get()) &&
|
||||
(e_config->screensaver_desklock_timeout > 0))
|
||||
timeout = e_config->screensaver_desklock_timeout;
|
||||
{
|
||||
timeout = e_config->screensaver_desklock_timeout;
|
||||
use_special_instead_of_dim = EINA_TRUE;
|
||||
}
|
||||
else
|
||||
timeout = e_config->screensaver_timeout * count;
|
||||
}
|
||||
|
||||
if ((use_idle) && (!e_config->mode.presentation))
|
||||
if ((use_idle) && (!e_config->mode.presentation) &&
|
||||
(!use_special_instead_of_dim))
|
||||
{
|
||||
if (e_config->backlight.idle_dim)
|
||||
{
|
||||
|
@ -553,9 +558,15 @@ e_screensaver_now_set(Eina_Bool now)
|
|||
E_API void
|
||||
e_screensaver_eval(Eina_Bool saver_on)
|
||||
{
|
||||
Eina_Bool use_special_instead_of_dim = EINA_FALSE;
|
||||
|
||||
if ((e_desklock_state_get()) &&
|
||||
(e_config->screensaver_desklock_timeout > 0))
|
||||
use_special_instead_of_dim = EINA_TRUE;
|
||||
if (saver_on)
|
||||
{
|
||||
if (e_config->backlight.idle_dim)
|
||||
if ((e_config->backlight.idle_dim) &&
|
||||
(!use_special_instead_of_dim))
|
||||
{
|
||||
double t = e_config->screensaver_timeout -
|
||||
e_config->backlight.timer;
|
||||
|
@ -588,7 +599,8 @@ e_screensaver_eval(Eina_Bool saver_on)
|
|||
if (screensaver_idle_timer)
|
||||
{
|
||||
E_FREE_FUNC(screensaver_idle_timer, ecore_timer_del);
|
||||
if (e_config->backlight.idle_dim)
|
||||
if ((e_config->backlight.idle_dim) &&
|
||||
(!use_special_instead_of_dim))
|
||||
{
|
||||
if (e_backlight_mode_get(NULL) != E_BACKLIGHT_MODE_NORMAL)
|
||||
e_backlight_mode_set(NULL, E_BACKLIGHT_MODE_NORMAL);
|
||||
|
|
Loading…
Reference in New Issue