[glibmm] Application, ActionGroup: Add Doxygen class documentation.
- From: José Alburquerque <jaalburqu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glibmm] Application, ActionGroup: Add Doxygen class documentation.
- Date: Thu, 4 Nov 2010 04:46:23 +0000 (UTC)
commit 55328e55bf35297e548422f574ae365ddf999638
Author: José Alburquerque <jaalburqu svn gnome org>
Date: Wed Nov 3 23:57:52 2010 -0400
Application, ActionGroup: Add Doxygen class documentation.
* gio/src/application.hg: Add class docs.
(is_valid): Renamed to id_is_valid().
* gio/src/actiongroup.hg: Added class docs.
* gio/src/dbuserror.hg: Typos.
ChangeLog | 9 +++++++++
gio/src/actiongroup.hg | 16 +++++++++++++++-
gio/src/application.hg | 46 ++++++++++++++++++++++++++++++++++++++++++++--
gio/src/dbuserror.hg | 4 ++--
4 files changed, 70 insertions(+), 5 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 9c0335d..76d9703 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2010-11-03 José Alburquerque <jaalburqu svn gnome org>
+
+ Application, ActionGroup: Add Doxygen class documentation.
+
+ * gio/src/application.hg: Add class docs.
+ (is_valid): Renamed to id_is_valid().
+ * gio/src/actiongroup.hg: Added class docs.
+ * gio/src/dbuserror.hg: Typos.
+
2010-11-03 Murray Cumming <murrayc murrayc com>
Fix the build with glib from git master.
diff --git a/gio/src/actiongroup.hg b/gio/src/actiongroup.hg
index e98dd98..0612101 100644
--- a/gio/src/actiongroup.hg
+++ b/gio/src/actiongroup.hg
@@ -30,7 +30,21 @@ typedef struct _GActionGroupInterface GActionGroupInterface;
namespace Gio
{
-/** TODO
+/** ActionGroup - a group of actions.
+ * ActionGroup represents a group of actions.
+ *
+ * Each action in the group has a unique name (which is a string). All method
+ * calls, except list_actions() take the name of an action as * an argument.
+ *
+ * The GActionGroup API is meant to be the 'public' API to the action group.
+ * The calls here are exactly the interaction that 'external forces' (eg: UI,
+ * incoming D-Bus messages, etc.) are supposed to have with actions.
+ * 'Internal' APIs (ie: ones meant only to be accessed by the action group
+ * implementation) are found on subclasses. This is why you will find -- for
+ * example -- get_action_enabled() but not an equivalent set() call.
+ *
+ * Signals are emitted on the action group in response to state changes on
+ * individual actions.
*/
class ActionGroup : public Glib::Interface
{
diff --git a/gio/src/application.hg b/gio/src/application.hg
index 1332a6d..d141912 100644
--- a/gio/src/application.hg
+++ b/gio/src/application.hg
@@ -31,7 +31,49 @@ _WRAP_ENUM(ApplicationFlags, GApplicationFlags, NO_GTYPE)
class ActionGroup;
-/** TODO
+/** Application - Core application class.
+ * A Application is the foundation of an application, unique for a given
+ * application identifier. The Application class wraps some low-level
+ * platform-specific services and is intended to act as the foundation for
+ * higher-level application classes such as Gtk::Application or MxApplication.
+ * In general, you should not use this class outside of a higher level
+ * framework.
+ *
+ * One of the core features that GApplication provides is process uniqueness,
+ * in the context of a "session". The session concept is platform-dependent,
+ * but corresponds roughly to a graphical desktop login. When your application
+ * is launched again, its arguments are passed through platform communication
+ * to the already running program. The already running instance of the program
+ * is called the <i>primary instance</i>.
+ *
+ * Before using Application, you must choose an "application identifier". The
+ * expected form of an application identifier is very close to that of of a
+ * <a href="
+ * http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-names-interface">DBus
+ * bus name</a>. Examples include: "com.example.MyApp",
+ * "org.example.internal-apps.Calculator". For details on valid application
+ * identifiers, see id_is_valid().
+ *
+ * Application provides convenient life cycle management by maintaining a
+ * <i>use count</i> for the primary application instance. The use count can be
+ * changed using hold() and release(). If it drops to zero, the application
+ * exits.
+ *
+ * GApplication also implements the ActionGroup interface and lets you easily
+ * export actions by adding them with set_action_group(). When
+ * invoking an action by calling Gio::ActionGroup::activate_action() on the
+ * application, it is always invoked in the primary instance.
+ *
+ * There is a number of different entry points into a Application:
+ *
+ * - via 'Activate' (i.e. just starting the application)
+ * - via 'Open' (i.e. opening some files)
+ * - via activating an action
+ *
+ * The signal_startup() signal lets you handle the application initialization
+ * for all of these in a single place.
+ *
+ * See the C API docs for an example.
*
* @newin{2,26}
*/
@@ -47,7 +89,7 @@ public:
_WRAP_METHOD(static Glib::RefPtr<Application> create(const Glib::ustring& appid, ApplicationFlags flags = APPLICATION_FLAGS_NONE), g_application_new)
- _WRAP_METHOD(static bool is_valid(const Glib::ustring& application_id), g_application_id_is_valid)
+ _WRAP_METHOD(static bool id_is_valid(const Glib::ustring& application_id), g_application_id_is_valid)
_WRAP_METHOD(Glib::ustring get_id() const, g_application_get_application_id)
_WRAP_METHOD(void set_id(const Glib::ustring& application_id), g_application_set_application_id)
diff --git a/gio/src/dbuserror.hg b/gio/src/dbuserror.hg
index 8699f37..deee1e9 100644
--- a/gio/src/dbuserror.hg
+++ b/gio/src/dbuserror.hg
@@ -47,7 +47,7 @@ bool is_remote_error(const Glib::Error& error);
* (e.g. Gio::DBusConnection::call_finish()) unless strip_remote_error() has
* been used on @a error.
*
- * @param error A GError.
+ * @param error A Glib::Error.
* @return An allocated string or 0 if the D-Bus error name could not be
* found.
* @newin{2,26}
@@ -60,7 +60,7 @@ Glib::ustring get_remote_error(const Glib::Error& error);
*
* This is typically used when presenting errors to the end user.
*
- * @param error A GError.
+ * @param error A Glib::Error.
* @return <tt>true</tt> if information was stripped, <tt>false</tt>
* otherwise.
* @newin{2,26}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]