summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2019-10-30 12:29:01 +0000
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2019-10-30 12:29:01 +0000
commit57a9f728a87ef43882fe1a47daf945d5a392336f (patch)
tree7309343eda1a319323701c2d21650d182d9b2a9d
parent7edb3550dd39d669a036b1a648601f60389259e7 (diff)
downloadenlightenment-57a9f728a87ef43882fe1a47daf945d5a392336f.tar.gz
acpi - delay missing acpid dialog until after we've started up
with a timer it'll wait untuil after mainloop is running before it times out and thus shows the dialog ensuring it appears once the compositor is fully up. this should avoid weird sized windows. @fix
-rw-r--r--src/bin/e_acpi.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/bin/e_acpi.c b/src/bin/e_acpi.c
index f98890985c..39d2bba0c1 100644
--- a/src/bin/e_acpi.c
+++ b/src/bin/e_acpi.c
@@ -125,6 +125,18 @@ static E_ACPI_Device_Multiplexed _devices_multiplexed[] =
/* public variables */
E_API int E_EVENT_ACPI = 0;
+static Eina_Bool
+_acpi_error_cb(void *data EINA_UNUSED)
+{
+ e_util_dialog_show
+ (_("ACPI Error"),
+ _("You seem to have an ACPI based system, but<br>"
+ "<hilight>acpid</hilight> does not seem to be running or<br>"
+ "contactable. Perhaps enable the <hilight>acpid</hilight><br>"
+ "service on your system?"));
+ return EINA_FALSE;
+}
+
/* public functions */
EINTERN int
e_acpi_init(void)
@@ -135,11 +147,7 @@ e_acpi_init(void)
if (!ecore_file_exists("/var/run/acpid.socket"))
{
if (ecore_file_exists("/proc/acpi"))
- e_util_dialog_show(_("Error"),
- _("You seem to have an ACPI based system, but<br>"
- "<hilight>acpid</hilight> does not seem to be running or<br>"
- "contactable. Perhaps enable the <hilight>acpid</hilight><br>"
- "service on your system?"));
+ ecore_timer_add(5.0, _acpi_error_cb, NULL);
return 1;
}