Review of attachment 568753:
-----------------------------------------------------------------
::: accessible/src/atk/nsApplicationAccessibleWrap.cpp
@@ +618,5 @@
> +test_a11y_dbus (bool *out)
> +{
> + // XXX following code is copied from widget/src/gtk2/nsWindow.cpp
> + // we should put it somewhere that can be used from both modules
> + // see bug 390761
Why not fix this now? You can just make the widget version nonstatic and call it from here.
Comment on attachment 568753
Proposed patch.
Review of attachment 568753: ------- ------- ------- ------- ------- ------- ------- ------- --
-------
::: accessible/ src/atk/ nsApplicationAc cessibleWrap. cpp src/gtk2/ nsWindow. cpp
@@ +618,5 @@
> +test_a11y_dbus (bool *out)
> +{
> + // XXX following code is copied from widget/
> + // we should put it somewhere that can be used from both modules
> + // see bug 390761
Why not fix this now? You can just make the widget version nonstatic and call it from here.
@@ +625,5 @@
> + DBusConnection *bus;
> + DBusMessage *message = NULL, *reply = NULL;
> + DBusMessageIter iter, iter_variant, iter_struct;
> + dbus_bool_t d_result;
> + DBusError error;
This is C++ code, just declare these where they're first assigned wherever possible
@@ +627,5 @@
> + DBusMessageIter iter, iter_variant, iter_struct;
> + dbus_bool_t d_result;
> + DBusError error;
> + const char *iface = "org.a11y.Status";
> + const char *member = "IsEnabled";
static const char iface[] = ...;
static const char member[] = ...;
@@ +636,5 @@ new_method_ call ("org.a11y.Bus", "/org/a11y/bus", p.DBus. Properties" ,
> + goto exit;
> +
> + message = dbus_message_
> + "org.freedeskto
> + "Get");
How fast is this? We're calling this on every widget creation, could this be slow?