// This file was generated by the Gtk# code generator.
// Any changes made will be lost if regenerated.

namespace Gnome {

	using System;
	using System.Runtime.InteropServices;

#region Autogenerated code
	public class Global {

		[DllImport("gnomeui-2", CallingConvention = CallingConvention.Cdecl)]
		static extern void gnome_interaction_key_return(int key, bool cancel_shutdown);

		public static void InteractionKeyReturn(int key, bool cancel_shutdown) {
			gnome_interaction_key_return(key, cancel_shutdown);
		}

		[DllImport("gnomeui-2", CallingConvention = CallingConvention.Cdecl)]
		static extern void gnome_type_init();

		public static void TypeInit() {
			gnome_type_init();
		}

		[DllImport("gnomeui-2", CallingConvention = CallingConvention.Cdecl)]
		static extern IntPtr gnome_master_client();

		public static Gnome.Client MasterClient() {
			IntPtr raw_ret = gnome_master_client();
			Gnome.Client ret = GLib.Object.GetObject(raw_ret) as Gnome.Client;
			return ret;
		}

		[DllImport("gnomeui-2", CallingConvention = CallingConvention.Cdecl)]
		static extern void gnome_ice_init();

		public static void IceInit() {
			gnome_ice_init();
		}

		[DllImport("gnomeui-2", CallingConvention = CallingConvention.Cdecl)]
		static extern unsafe bool gnome_url_show_on_screen(IntPtr url, IntPtr screen, out IntPtr error);

		public static unsafe bool UrlShowOnScreen(string url, Gdk.Screen screen) {
			IntPtr native_url = GLib.Marshaller.StringToPtrGStrdup (url);
			IntPtr error = IntPtr.Zero;
			bool raw_ret = gnome_url_show_on_screen(native_url, screen == null ? IntPtr.Zero : screen.Handle, out error);
			bool ret = raw_ret;
			GLib.Marshaller.Free (native_url);
			if (error != IntPtr.Zero) throw new GLib.GException (error);
			return ret;
		}

		[DllImport("gnomeui-2", CallingConvention = CallingConvention.Cdecl)]
		static extern void gnome_accelerators_sync();

		public static void AcceleratorsSync() {
			gnome_accelerators_sync();
		}

#endregion
	}
}
