diff options
author | Murray Cumming <murrayc@murrayc.com> | 2016-03-31 12:52:18 +0200 |
---|---|---|
committer | Murray Cumming <murrayc@murrayc.com> | 2016-11-14 10:43:21 +0100 |
commit | 0ca323351606b0fa2f8519155a3edd0cc6a51805 (patch) | |
tree | aa6c49839339fba57c32a8be1382751cfff8802a /gio | |
parent | de11e59c1f275556e73e4747e8ba75763dac9045 (diff) | |
download | glibmm-0ca323351606b0fa2f8519155a3edd0cc6a51805.tar.gz |
sigc3: .hg/.ccg files: Use sigc::slot<R(Args...)> syntax.
Diffstat (limited to 'gio')
-rw-r--r-- | gio/src/actionmap.hg | 10 | ||||
-rw-r--r-- | gio/src/application.ccg | 4 | ||||
-rw-r--r-- | gio/src/asyncresult.hg | 2 | ||||
-rw-r--r-- | gio/src/cancellable.hg | 2 | ||||
-rw-r--r-- | gio/src/dbusconnection.hg | 8 | ||||
-rw-r--r-- | gio/src/dbusinterfacevtable.hg | 12 | ||||
-rw-r--r-- | gio/src/dbusownname.hg | 6 | ||||
-rw-r--r-- | gio/src/dbussubtreevtable.hg | 12 | ||||
-rw-r--r-- | gio/src/dbuswatchname.hg | 4 | ||||
-rw-r--r-- | gio/src/file.hg | 6 | ||||
-rw-r--r-- | gio/src/liststore.hg | 4 | ||||
-rw-r--r-- | gio/src/memoryinputstream.hg | 2 |
12 files changed, 36 insertions, 36 deletions
diff --git a/gio/src/actionmap.hg b/gio/src/actionmap.hg index 22241f12..e3bcdf0c 100644 --- a/gio/src/actionmap.hg +++ b/gio/src/actionmap.hg @@ -59,7 +59,7 @@ public: * For instance, * void on_slot_activated(const Glib::VariantBase& parameter); */ - using ActivateWithParameterSlot = sigc::slot<void, const Glib::VariantBase&>; + using ActivateWithParameterSlot = sigc::slot<void(const Glib::VariantBase&)>; //This is an equivalent for g_action_map_add_action_entries(). /** A convenience method for creating a SimpleAction instance @@ -88,7 +88,7 @@ public: * For instance, * void on_slot_activated(); */ - using ActivateSlot = sigc::slot<void>; + using ActivateSlot = sigc::slot<void()>; /** A convenience method for creating a SimpleAction instance * and adding it to the ActionMap. @@ -136,7 +136,7 @@ public: * For instance, * void on_slot_activated(const Glib::VariantBase& parameter); */ - using ActivateWithStringParameterSlot = sigc::slot<void, const Glib::ustring&>; + using ActivateWithStringParameterSlot = sigc::slot<void(const Glib::ustring&)>; //TODO: Docs: Add hints about how to specify the various possible states in the GtkBuilder XML. /** A convenience method for creating a string-based radio SimpleAction instance @@ -165,8 +165,8 @@ public: * For instance, * void on_slot_activated(const Glib::VariantBase& parameter); */ - using ActivateWithIntParameterSlot = sigc::slot<void, int>; - + using ActivateWithIntParameterSlot = sigc::slot<void(int)>; + //TODO: Docs: Add hints about how to specify the various possible states in the GtkBuilder XML. /** A convenience method for creating an integer-based radio SimpleAction instance * and adding it to the ActionMap. diff --git a/gio/src/application.ccg b/gio/src/application.ccg index 7b53edf2..75e876d6 100644 --- a/gio/src/application.ccg +++ b/gio/src/application.ccg @@ -57,7 +57,7 @@ static void Application_signal_open_callback( GApplication* self, GFile** files, gint n_files, const gchar* hint, void* data) { - using SlotType = sigc::slot<void, const Gio::Application::type_vec_files&, const Glib::ustring&>; + using SlotType = sigc::slot<void(const Gio::Application::type_vec_files&, const Glib::ustring&)>; Gio::Application::type_vec_files vec_files(n_files); for (int i = 0; i < n_files; ++i) @@ -92,7 +92,7 @@ Application_signal_open_notify_callback( GApplication* self, GFile** files, gint n_files, const gchar* hint, void* data) { using namespace Gio; - using SlotType = sigc::slot<void, const Application::type_vec_files&, const Glib::ustring&>; + using SlotType = sigc::slot<void(const Application::type_vec_files&, const Glib::ustring&)>; Application::type_vec_files vec_files(n_files); for (int i = 0; i < n_files; i++) diff --git a/gio/src/asyncresult.hg b/gio/src/asyncresult.hg index 7d9567c7..681b3802 100644 --- a/gio/src/asyncresult.hg +++ b/gio/src/asyncresult.hg @@ -42,7 +42,7 @@ class AsyncResult; * * @newin{2,16} */ -using SlotAsyncReady = sigc::slot<void, Glib::RefPtr<AsyncResult>&>; +using SlotAsyncReady = sigc::slot<void(Glib::RefPtr<AsyncResult>&)>; /** Provides a base class for implementing asynchronous function results. * Asynchronous operations are broken up into two separate operations which are chained together by a SlotAsyncReady. diff --git a/gio/src/cancellable.hg b/gio/src/cancellable.hg index fc8bff85..a1cc68ab 100644 --- a/gio/src/cancellable.hg +++ b/gio/src/cancellable.hg @@ -37,7 +37,7 @@ protected: _CTOR_DEFAULT public: - using SlotCancelledCallback = sigc::slot<void>; + using SlotCancelledCallback = sigc::slot<void()>; _WRAP_CREATE() diff --git a/gio/src/dbusconnection.hg b/gio/src/dbusconnection.hg index 6b0e5587..96b65c8e 100644 --- a/gio/src/dbusconnection.hg +++ b/gio/src/dbusconnection.hg @@ -173,9 +173,9 @@ public: * Glib::ustring& signal_name, const Glib::VariantContainerBase& parameters);. * @endcode */ - using SlotSignal = sigc::slot<void, const Glib::RefPtr<Connection>&, + using SlotSignal = sigc::slot<void(const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, - const Glib::ustring&, const Glib::VariantContainerBase&>; + const Glib::ustring&, const Glib::VariantContainerBase&)>; /** Signature for slot used in add_filter(). * For example, @@ -191,9 +191,9 @@ public: * drop a message can simply return <tt>0</tt>. And filter function may * modify a message by copying it and return the copy. */ - using SlotMessageFilter = sigc::slot<Glib::RefPtr<Message>, + using SlotMessageFilter = sigc::slot<Glib::RefPtr<Message>( const Glib::RefPtr<Connection>&, - const Glib::RefPtr<Message>&, bool>; + const Glib::RefPtr<Message>&, bool)>; /** Asynchronously connects to the message bus specified by @a bus_type. * diff --git a/gio/src/dbusinterfacevtable.hg b/gio/src/dbusinterfacevtable.hg index caf181a7..c4081e7d 100644 --- a/gio/src/dbusinterfacevtable.hg +++ b/gio/src/dbusinterfacevtable.hg @@ -63,14 +63,14 @@ public: * @endcode */ using SlotInterfaceMethodCall = sigc::slot< - void, + void( const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, const Glib::VariantContainerBase&, - const Glib::RefPtr<MethodInvocation>& + const Glib::RefPtr<MethodInvocation>&) >; /** The type for a slot which handles getting a property for a D-Bus @@ -85,13 +85,13 @@ public: * @throw Glib::Error. */ using SlotInterfaceGetProperty = sigc::slot< - void, + void( Glib::VariantBase&, const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, - const Glib::ustring& + const Glib::ustring&) >; /** The type for a slot which handles setting a property for a D-Bus @@ -106,13 +106,13 @@ public: * @throw Glib::Error. */ using SlotInterfaceSetProperty = sigc::slot< - bool, + bool( const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, - const Glib::VariantBase& + const Glib::VariantBase&) >; /** Constructs a new InterfaceVTable using the specified slots. diff --git a/gio/src/dbusownname.hg b/gio/src/dbusownname.hg index 8690d104..5944f436 100644 --- a/gio/src/dbusownname.hg +++ b/gio/src/dbusownname.hg @@ -35,21 +35,21 @@ _WRAP_ENUM(BusNameOwnerFlags, GBusNameOwnerFlags, s#^DBUS_##) * @newin{2,28} * @ingroup DBus */ -using SlotBusAcquired = sigc::slot<void, const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring>; +using SlotBusAcquired = sigc::slot<void(const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring)>; /** For example, * void on_name_acquired(const Glib::RefPtr<Gio::DBus::Connection>& connection, * const Glib::ustring& name); * @ingroup DBus */ -using SlotNameAcquired = sigc::slot<void, const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring>; +using SlotNameAcquired = sigc::slot<void(const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring)>; /** For example, * void on_name_lost(const Glib::RefPtr<Gio::DBus::Connection>& connection, * const Glib::ustring& name); * @ingroup DBus */ -using SlotNameLost = sigc::slot<void, const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring>; +using SlotNameLost = sigc::slot<void(const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring)>; //TODO: See https://bugzilla.gnome.org/show_bug.cgi?id=646427 about the apparent uselessness of SlotNameAcquired. //TODO: Add example from C API in class docs. diff --git a/gio/src/dbussubtreevtable.hg b/gio/src/dbussubtreevtable.hg index ead80eea..3c2d6d87 100644 --- a/gio/src/dbussubtreevtable.hg +++ b/gio/src/dbussubtreevtable.hg @@ -67,10 +67,10 @@ public: * @endcode */ using SlotSubtreeEnumerate = sigc::slot< - std::vector<Glib::ustring>, + std::vector<Glib::ustring>( const Glib::RefPtr<Connection>&, const Glib::ustring&, - const Glib::ustring& + const Glib::ustring&) >; /** The type for a slot which handles introspecting a child node. @@ -94,11 +94,11 @@ public: * @endcode */ using SlotSubtreeIntrospect = sigc::slot< - std::vector< Glib::RefPtr<Gio::DBus::InterfaceInfo> >, + std::vector< Glib::RefPtr<Gio::DBus::InterfaceInfo> >( const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, - const Glib::ustring& + const Glib::ustring&) >; /** The type for a slot which handles dispatching a remote call on a child @@ -116,12 +116,12 @@ public: * @endcode */ using SlotSubtreeDispatch = sigc::slot< - const InterfaceVTable*, + const InterfaceVTable*( const Glib::RefPtr<Connection>&, const Glib::ustring&, const Glib::ustring&, const Glib::ustring&, - const Glib::ustring& + const Glib::ustring&) >; /** Constructs a new SubtreeVTable using specified slots. diff --git a/gio/src/dbuswatchname.hg b/gio/src/dbuswatchname.hg index dd697ce0..63cdab4a 100644 --- a/gio/src/dbuswatchname.hg +++ b/gio/src/dbuswatchname.hg @@ -34,14 +34,14 @@ _WRAP_ENUM(BusNameWatcherFlags, GBusNameWatcherFlags, s#^DBUS_##, NO_GTYPE) * const Glib::ustring& name, const Glib::ustring& name_owner); * @ingroup DBus */ -using SlotNameAppeared = sigc::slot<void, const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring, const Glib::ustring&>; +using SlotNameAppeared = sigc::slot<void(const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring, const Glib::ustring&)>; /** For example, * void on_name_vanished(const Glib::RefPtr<Gio::DBus::Connection>& connection, * const Glib::ustring& name); * @ingroup DBus */ -using SlotNameVanished = sigc::slot<void, const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring>; +using SlotNameVanished = sigc::slot<void(const Glib::RefPtr<Gio::DBus::Connection>&, Glib::ustring)>; //TODO: Add example from C API in class docs? /** Starts watching @a name on the bus specified by @a bus_type and calls diff --git a/gio/src/file.hg b/gio/src/file.hg index 25c182f2..cbe8bac1 100644 --- a/gio/src/file.hg +++ b/gio/src/file.hg @@ -1118,7 +1118,7 @@ public: /** A signal handler would be, for instance: * void on_file_progress(goffset current_num_bytes, goffset total_num_bytes); */ - using SlotFileProgress = sigc::slot<void, goffset, goffset>; + using SlotFileProgress = sigc::slot<void(goffset, goffset)>; /** Copies the file source to the location specified by destination. Can not handle recursive copies of directories. * If the flag FILE_COPY_OVERWRITE is specified an already existing destination file is overwritten. @@ -1803,7 +1803,7 @@ public: * * @newin{2,38} */ - using SlotFileMeasureProgress = sigc::slot<void, bool, guint64, guint64, guint64>; + using SlotFileMeasureProgress = sigc::slot<void(bool, guint64, guint64, guint64)>; //We do not use the {callback} syntax with _WRAP_METHOD here, because it expects to use user_data rather than progress_data. //We ignore the gboolean result, because we throw an exception if it is false. @@ -2097,7 +2097,7 @@ public: /** A signal handler would be, for instance: * bool on_read_more(const char* file_contents, goffset file_size); */ - using SlotReadMore = sigc::slot<bool, const char*, goffset>; + using SlotReadMore = sigc::slot<bool(const char*, goffset)>; //Note that slot_read_more can be nullptr but that would not be a useful method overload, because the documentation says that it would //then be equivalent to load_contents_async. diff --git a/gio/src/liststore.hg b/gio/src/liststore.hg index 840d7397..2b3af6cf 100644 --- a/gio/src/liststore.hg +++ b/gio/src/liststore.hg @@ -63,7 +63,7 @@ public: * * @newin{2,50} */ - using SlotCompare = sigc::slot<int, const Glib::RefPtr<const Glib::ObjectBase>&, const Glib::RefPtr<const Glib::ObjectBase>&>; + using SlotCompare = sigc::slot<int(const Glib::RefPtr<const Glib::ObjectBase>&, const Glib::RefPtr<const Glib::ObjectBase>&)>; _WRAP_METHOD(guint insert_sorted(const Glib::RefPtr<Glib::ObjectBase>& item, const SlotCompare& slot{compare_func}), g_list_store_insert_sorted, @@ -175,7 +175,7 @@ public: * * @newin{2,50} */ - using SlotCompare = sigc::slot<int, const Glib::RefPtr<const T_item>&, const Glib::RefPtr<const T_item>&>; + using SlotCompare = sigc::slot<int(const Glib::RefPtr<const T_item>&, const Glib::RefPtr<const T_item>&)>; /** Inserts @a item at a position to be determined by the @a slot. * diff --git a/gio/src/memoryinputstream.hg b/gio/src/memoryinputstream.hg index 0fc03f4a..80bac202 100644 --- a/gio/src/memoryinputstream.hg +++ b/gio/src/memoryinputstream.hg @@ -76,7 +76,7 @@ _DEPRECATE_IFDEF_END * * @newin{2,40} */ - using SlotDestroyData = sigc::slot<void, void*>; + using SlotDestroyData = sigc::slot<void(void*)>; /** Appends to data that can be read from the input stream. * |