 6b26664c41
			
		
	
	6b26664c41
	
	
	
		
			
			Provide a mechanism for hiding the "Quit", "About" and "Preferences" menu items from the normal places in a traditional menubar layout (in the File and Edit menus) when the menu is being rendered in the Mac OS menubar. These items can already be found in the application menu. With this feature, applications can now define a single menu to use in all 'traditional' scenarios. Use this new attribute in Bloatpad. https://bugzilla.gnome.org/show_bug.cgi?id=741610
		
			
				
	
	
		
			96 lines
		
	
	
		
			4.7 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			96 lines
		
	
	
		
			4.7 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
| /*
 | |
|  * Copyright © 2011, 2013 Canonical Limited
 | |
|  *
 | |
|  * This library is free software; you can redistribute it and/or
 | |
|  * modify it under the terms of the GNU Lesser General Public
 | |
|  * License as published by the Free Software Foundation; either
 | |
|  * version 2 of the licence, or (at your option) any later version.
 | |
|  *
 | |
|  * This library is distributed in the hope that it will be useful,
 | |
|  * but WITHOUT ANY WARRANTY; without even the implied warranty of
 | |
|  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 | |
|  * Lesser General Public License for more details.
 | |
|  *
 | |
|  * You should have received a copy of the GNU Lesser General Public
 | |
|  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
 | |
|  *
 | |
|  * Author: Ryan Lortie <desrt@desrt.ca>
 | |
|  */
 | |
| 
 | |
| #ifndef __GTK_MENU_TRACKER_ITEM_H__
 | |
| #define __GTK_MENU_TRACKER_ITEM_H__
 | |
| 
 | |
| #include "gtkactionobservable.h"
 | |
| 
 | |
| #define GTK_TYPE_MENU_TRACKER_ITEM                          (gtk_menu_tracker_item_get_type ())
 | |
| #define GTK_MENU_TRACKER_ITEM(inst)                         (G_TYPE_CHECK_INSTANCE_CAST ((inst), \
 | |
|                                                              GTK_TYPE_MENU_TRACKER_ITEM, GtkMenuTrackerItem))
 | |
| #define GTK_IS_MENU_TRACKER_ITEM(inst)                      (G_TYPE_CHECK_INSTANCE_TYPE ((inst), \
 | |
|                                                              GTK_TYPE_MENU_TRACKER_ITEM))
 | |
| 
 | |
| typedef struct _GtkMenuTrackerItem GtkMenuTrackerItem;
 | |
| 
 | |
| #define GTK_TYPE_MENU_TRACKER_ITEM_ROLE                     (gtk_menu_tracker_item_role_get_type ())
 | |
| 
 | |
| typedef enum  {
 | |
|   GTK_MENU_TRACKER_ITEM_ROLE_NORMAL,
 | |
|   GTK_MENU_TRACKER_ITEM_ROLE_CHECK,
 | |
|   GTK_MENU_TRACKER_ITEM_ROLE_RADIO,
 | |
| } GtkMenuTrackerItemRole;
 | |
| 
 | |
| GType                   gtk_menu_tracker_item_get_type                  (void) G_GNUC_CONST;
 | |
| 
 | |
| GType                   gtk_menu_tracker_item_role_get_type             (void) G_GNUC_CONST;
 | |
| 
 | |
| GtkMenuTrackerItem *   _gtk_menu_tracker_item_new                       (GtkActionObservable *observable,
 | |
|                                                                          GMenuModel          *model,
 | |
|                                                                          gint                 item_index,
 | |
|                                                                          gboolean             mac_os_mode,
 | |
|                                                                          const gchar         *action_namespace,
 | |
|                                                                          gboolean             is_separator);
 | |
| 
 | |
| const gchar *           gtk_menu_tracker_item_get_special               (GtkMenuTrackerItem *self);
 | |
| 
 | |
| const gchar *           gtk_menu_tracker_item_get_display_hint          (GtkMenuTrackerItem *self);
 | |
| 
 | |
| GtkActionObservable *  _gtk_menu_tracker_item_get_observable            (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_is_separator          (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_has_link              (GtkMenuTrackerItem *self,
 | |
|                                                                          const gchar        *link_name);
 | |
| 
 | |
| const gchar *           gtk_menu_tracker_item_get_label                 (GtkMenuTrackerItem *self);
 | |
| 
 | |
| GIcon *                 gtk_menu_tracker_item_get_icon                  (GtkMenuTrackerItem *self);
 | |
| 
 | |
| GIcon *                 gtk_menu_tracker_item_get_verb_icon             (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_sensitive             (GtkMenuTrackerItem *self);
 | |
| 
 | |
| GtkMenuTrackerItemRole  gtk_menu_tracker_item_get_role                  (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_toggled               (GtkMenuTrackerItem *self);
 | |
| 
 | |
| const gchar *           gtk_menu_tracker_item_get_accel                 (GtkMenuTrackerItem *self);
 | |
| 
 | |
| GMenuModel *           _gtk_menu_tracker_item_get_link                  (GtkMenuTrackerItem *self,
 | |
|                                                                          const gchar        *link_name);
 | |
| 
 | |
| gchar *                _gtk_menu_tracker_item_get_link_namespace        (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_may_disappear             (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_is_visible            (GtkMenuTrackerItem *self);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_should_request_show   (GtkMenuTrackerItem *self);
 | |
| 
 | |
| void                    gtk_menu_tracker_item_activated                 (GtkMenuTrackerItem *self);
 | |
| 
 | |
| void                    gtk_menu_tracker_item_request_submenu_shown     (GtkMenuTrackerItem *self,
 | |
|                                                                          gboolean            shown);
 | |
| 
 | |
| gboolean                gtk_menu_tracker_item_get_submenu_shown         (GtkMenuTrackerItem *self);
 | |
| 
 | |
| #endif
 |