您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 
 
 
 

75 行
3.1 KiB

  1. /* GTK - The GIMP Toolkit
  2. * Recent chooser action for GtkUIManager
  3. *
  4. * Copyright (C) 2007, Emmanuele Bassi
  5. *
  6. * This library is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU Lesser General Public
  8. * License as published by the Free Software Foundation; either
  9. * version 2 of the License, or (at your option) any later version.
  10. *
  11. * This library is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  14. * Lesser General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU Lesser General Public
  17. * License along with this library; if not, write to the
  18. * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  19. * Boston, MA 02111-1307, USA.
  20. */
  21. #if defined(GTK_DISABLE_SINGLE_INCLUDES) && !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
  22. #error "Only <gtk/gtk.h> can be included directly."
  23. #endif
  24. #ifndef __GTK_RECENT_ACTION_H__
  25. #define __GTK_RECENT_ACTION_H__
  26. #include <gtk/gtkaction.h>
  27. #include <gtk/gtkrecentmanager.h>
  28. G_BEGIN_DECLS
  29. #define GTK_TYPE_RECENT_ACTION (gtk_recent_action_get_type ())
  30. #define GTK_RECENT_ACTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_RECENT_ACTION, GtkRecentAction))
  31. #define GTK_IS_RECENT_ACTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_RECENT_ACTION))
  32. #define GTK_RECENT_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_RECENT_ACTION, GtkRecentActionClass))
  33. #define GTK_IS_RECENT_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_RECENT_ACTION))
  34. #define GTK_RECENT_ACTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_RECENT_ACTION, GtkRecentActionClass))
  35. typedef struct _GtkRecentAction GtkRecentAction;
  36. typedef struct _GtkRecentActionPrivate GtkRecentActionPrivate;
  37. typedef struct _GtkRecentActionClass GtkRecentActionClass;
  38. struct _GtkRecentAction
  39. {
  40. GtkAction parent_instance;
  41. /*< private >*/
  42. GtkRecentActionPrivate *GSEAL (priv);
  43. };
  44. struct _GtkRecentActionClass
  45. {
  46. GtkActionClass parent_class;
  47. };
  48. GType gtk_recent_action_get_type (void) G_GNUC_CONST;
  49. GtkAction *gtk_recent_action_new (const gchar *name,
  50. const gchar *label,
  51. const gchar *tooltip,
  52. const gchar *stock_id);
  53. GtkAction *gtk_recent_action_new_for_manager (const gchar *name,
  54. const gchar *label,
  55. const gchar *tooltip,
  56. const gchar *stock_id,
  57. GtkRecentManager *manager);
  58. gboolean gtk_recent_action_get_show_numbers (GtkRecentAction *action);
  59. void gtk_recent_action_set_show_numbers (GtkRecentAction *action,
  60. gboolean show_numbers);
  61. G_END_DECLS
  62. #endif /* __GTK_RECENT_ACTION_H__ */