Ardour  8.7-15-gadf511264b
recentinfo.h
Go to the documentation of this file.
1 // -*- c++ -*-
2 // Generated by gmmproc 2.45.3 -- DO NOT MODIFY!
3 #ifndef _GTKMM_RECENTINFO_H
4 #define _GTKMM_RECENTINFO_H
5 
6 
7 #include <glibmm/ustring.h>
8 #include <sigc++/sigc++.h>
9 
10 /* Copyright (C) 2006 The gtkmm Development Team
11  *
12  * This library is free software; you can redistribute it and/or
13  * modify it under the terms of the GNU Lesser General Public
14  * License as published by the Free Software Foundation; either
15  * version 2.1 of the License, or (at your option) any later version.
16  *
17  * This library is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20  * Lesser General Public License for more details.
21  *
22  * You should have received a copy of the GNU Lesser General Public
23  * License along with this library; if not, write to the Free
24  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
25  */
26 
27 #include <gdkmm/pixbuf.h>
28 #include <ctime>
29 
30 
31 #ifndef DOXYGEN_SHOULD_SKIP_THIS
32 extern "C"
33 {
34 typedef struct _GtkRecentInfo GtkRecentInfo;
36 }
37 #endif /* !DOXYGEN_SHOULD_SKIP_THIS */
38 
39 namespace Gtk
40 {
41 
48 {
49  public:
50 #ifndef DOXYGEN_SHOULD_SKIP_THIS
51  typedef RecentInfo CppObjectType;
52  typedef GtkRecentInfo BaseObjectType;
53 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
54 
55 
59  void reference() const;
60 
64  void unreference() const;
65 
68 
70  const GtkRecentInfo* gobj() const;
71 
74 
75 protected:
76  // Do not derive this. Gtk::RecentInfo can neither be constructed nor deleted.
78  void operator delete(void*, std::size_t);
79 
80 private:
81  // noncopyable
84 
85 
86 public:
87 
88 
89 //TODO: Deprecate this? Why? Document the deprecation.
90 //#ifndef DOXYGEN_SHOULD_SKIP_THIS
91 //# if (!defined(GTKMM_DISABLE_DEPRECATED) || defined(GTKMM_COMPILATION))
93  operator bool() const;
94 //# endif
95 //#endif
96 
97 
103  Glib::ustring get_uri() const;
104 
111  Glib::ustring get_display_name() const;
112 
118  Glib::ustring get_description() const;
119 
125  Glib::ustring get_mime_type() const;
126 
127 
134  time_t get_added() const;
135 
142  time_t get_modified() const;
143 
150  time_t get_visited() const;
151 
152 
159  bool get_private_hint() const;
160 
161 
179  bool get_application_info(const Glib::ustring& app_name, std::string& app_exec,
180  guint& count, time_t& time) const;
181 
182 
190  Glib::StringArrayHandle get_applications() const;
191 
192 
198  Glib::ustring last_application() const;
199 
206  bool has_application(const Glib::ustring& app_name) const;
207 
208 
218  Glib::StringArrayHandle get_groups() const;
219 
220 
227  bool has_group(const Glib::ustring& group) const;
228 
229 
236  Glib::RefPtr<Gdk::Pixbuf> get_icon(int size);
237 
244  Glib::RefPtr<const Gdk::Pixbuf> get_icon(int size) const;
245 
246 
254  Glib::ustring get_short_name() const;
255 
263  Glib::ustring get_uri_display() const;
264 
265 
272  int get_age() const;
273 
279  bool is_local() const;
280 
286  bool exists() const;
287 
288 
296  bool equal(const RecentInfo& b) const;
297 
298 
299 };
300 
301 #ifndef DOXYGEN_SHOULD_SKIP_THIS
302 
303 struct RecentInfoTraits
304 {
305  typedef Glib::RefPtr<RecentInfo> CppType;
306  typedef const GtkRecentInfo* CType;
307  typedef GtkRecentInfo* CTypeNonConst;
308 
309  static inline CType to_c_type(const CppType& obj) { return Glib::unwrap(obj); }
310  static inline CType to_c_type(const CType& obj) { return obj; }
311  static CppType to_cpp_type(const CType& obj);
312  static inline void release_c_type(const CType& obj)
313  { gtk_recent_info_unref(const_cast<CTypeNonConst>(obj)); }
314 };
315 #endif /* !DOXYGEN_SHOULD_SKIP_THIS */
316 
317 // TODO: These are almost impossible to use without RefPtr<>::operator*()
318 
320 inline bool operator==(const RecentInfo& lhs, const RecentInfo& rhs)
321  { return lhs.equal(rhs); }
322 
324 inline bool operator!=(const RecentInfo& lhs, const RecentInfo& rhs)
325  { return !lhs.equal(rhs); }
326 
327 } // namespace Gtk
328 
329 namespace Glib
330 {
331 
332 // This is needed so Glib::RefPtr<Gtk::RecentInfo> can be used with
333 // Glib::Value and Gtk::TreeModelColumn:
334 template <>
335 class Value< Glib::RefPtr<Gtk::RecentInfo> > : public ValueBase_Boxed
336 {
337 public:
338  typedef Glib::RefPtr<Gtk::RecentInfo> CppType;
340 
341  static GType value_type();
342 
343  void set(const CppType& data);
344  CppType get() const;
345 };
346 
347 } // namespace Glib
348 
349 
350 namespace Glib
351 {
352 
361  Glib::RefPtr<Gtk::RecentInfo> wrap(GtkRecentInfo* object, bool take_copy = false);
362 
363 } // namespace Glib
364 
365 
366 #endif /* _GTKMM_RECENTINFO_H */
367 
Glib::RefPtr< Gtk::RecentInfo > CppType
Definition: recentinfo.h:338
RecentInfo & operator=(const RecentInfo &)
Glib::RefPtr< const Gdk::Pixbuf > get_icon(int size) const
bool equal(const RecentInfo &b) const
int get_age() const
time_t get_added() const
Glib::StringArrayHandle get_applications() const
bool get_application_info(const Glib::ustring &app_name, std::string &app_exec, guint &count, time_t &time) const
bool exists() const
bool has_application(const Glib::ustring &app_name) const
Glib::ustring get_mime_type() const
const GtkRecentInfo * gobj() const
Provides access to the underlying C instance.
GtkRecentInfo * gobj_copy() const
Provides access to the underlying C instance. The caller is responsible for unrefing it....
Glib::ustring get_short_name() const
bool has_group(const Glib::ustring &group) const
time_t get_visited() const
Glib::ustring get_uri_display() const
void unreference() const
Glib::ustring get_display_name() const
Glib::StringArrayHandle get_groups() const
bool is_local() const
Glib::RefPtr< Gdk::Pixbuf > get_icon(int size)
Glib::ustring get_description() const
Glib::RefPtr< Gtk::RecentInfo > wrap(GtkRecentInfo *object, bool take_copy=false)
Glib::ustring last_application() const
void reference() const
GtkRecentInfo * gobj()
Provides access to the underlying C instance.
bool get_private_hint() const
time_t get_modified() const
bool operator==(const RecentInfo &lhs, const RecentInfo &rhs)
Definition: recentinfo.h:320
Glib::ustring get_uri() const
RecentInfo(const RecentInfo &)
bool operator!=(const RecentInfo &lhs, const RecentInfo &rhs)
Definition: recentinfo.h:324
struct _GtkRecentInfo GtkRecentInfo
void gtk_recent_info_unref(GtkRecentInfo *info)
Definition: ardour_ui.h:188
Transmitter info
Definition: lobject.h:100