Blame lib/bluetooth-pairing-dialog.h

Packit 8fb625
/*
Packit 8fb625
 *
Packit 8fb625
 *  Copyright (C) 2013 Bastien Nocera <hadess@hadess.net>
Packit 8fb625
 *
Packit 8fb625
 *  This library is free software; you can redistribute it and/or
Packit 8fb625
 *  modify it under the terms of the GNU Lesser General Public
Packit 8fb625
 *  License as published by the Free Software Foundation; either
Packit 8fb625
 *  version 2.1 of the License, or (at your option) any later version.
Packit 8fb625
 *
Packit 8fb625
 *  This library is distributed in the hope that it will be useful,
Packit 8fb625
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 8fb625
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 8fb625
 *  Lesser General Public License for more details.
Packit 8fb625
 *
Packit 8fb625
 *  You should have received a copy of the GNU Lesser General Public
Packit 8fb625
 *  License along with this library; if not, write to the Free Software
Packit 8fb625
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
Packit 8fb625
 *
Packit 8fb625
 */
Packit 8fb625
Packit 8fb625
#ifndef __BLUETOOTH_PAIRING_DIALOG_H
Packit 8fb625
#define __BLUETOOTH_PAIRING_DIALOG_H
Packit 8fb625
Packit 8fb625
#include <gtk/gtk.h>
Packit 8fb625
Packit 8fb625
G_BEGIN_DECLS
Packit 8fb625
Packit 8fb625
#define BLUETOOTH_TYPE_PAIRING_DIALOG (bluetooth_pairing_dialog_get_type())
Packit 8fb625
#define BLUETOOTH_PAIRING_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \
Packit 8fb625
				BLUETOOTH_TYPE_PAIRING_DIALOG, BluetoothPairingDialog))
Packit 8fb625
#define BLUETOOTH_PAIRING_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), \
Packit 8fb625
				BLUETOOTH_TYPE_PAIRING_DIALOG, BluetoothPairingDialogClass))
Packit 8fb625
#define BLUETOOTH_IS_PAIRING_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), \
Packit 8fb625
						BLUETOOTH_TYPE_PAIRING_DIALOG))
Packit 8fb625
#define BLUETOOTH_IS_PAIRING_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), \
Packit 8fb625
						BLUETOOTH_TYPE_PAIRING_DIALOG))
Packit 8fb625
#define BLUETOOTH_GET_PAIRING_DIALOG_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), \
Packit 8fb625
				BLUETOOTH_TYPE_PAIRING_DIALOG, BluetoothPairingDialogClass))
Packit 8fb625
Packit 8fb625
/**
Packit 8fb625
 * BluetoothPairingDialog:
Packit 8fb625
 *
Packit 8fb625
 * The <structname>BluetoothPairingDialog</structname> struct contains
Packit 8fb625
 * only private fields and should not be directly accessed.
Packit 8fb625
 */
Packit 8fb625
typedef struct _BluetoothPairingDialog BluetoothPairingDialog;
Packit 8fb625
typedef struct _BluetoothPairingDialogClass BluetoothPairingDialogClass;
Packit 8fb625
Packit 8fb625
struct _BluetoothPairingDialog {
Packit 8fb625
	GtkDialog parent;
Packit 8fb625
};
Packit 8fb625
Packit 8fb625
struct _BluetoothPairingDialogClass {
Packit 8fb625
	GtkDialogClass parent_class;
Packit 8fb625
};
Packit 8fb625
Packit 8fb625
typedef enum {
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_PIN_QUERY,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_PIN_CONFIRMATION,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_PIN_DISPLAY_NORMAL,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_PIN_DISPLAY_KEYBOARD,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_PIN_DISPLAY_ICADE,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_PIN_MATCH,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_YES_NO,
Packit 8fb625
	BLUETOOTH_PAIRING_MODE_CONFIRM_AUTH
Packit 8fb625
} BluetoothPairingMode;
Packit 8fb625
Packit 8fb625
GType bluetooth_pairing_dialog_get_type (void);
Packit 8fb625
Packit 8fb625
GtkWidget *bluetooth_pairing_dialog_new (void);
Packit 8fb625
Packit 8fb625
void bluetooth_pairing_dialog_set_mode (BluetoothPairingDialog *self,
Packit 8fb625
					BluetoothPairingMode    mode,
Packit 8fb625
					const char             *pin,
Packit 8fb625
					const char             *name);
Packit 8fb625
BluetoothPairingMode bluetooth_pairing_dialog_get_mode (BluetoothPairingDialog *self);
Packit 8fb625
Packit 8fb625
void bluetooth_pairing_dialog_set_pin_entered (BluetoothPairingDialog *self,
Packit 8fb625
					       guint                   entered);
Packit 8fb625
Packit 8fb625
char *bluetooth_pairing_dialog_get_pin (BluetoothPairingDialog *self);
Packit 8fb625
Packit 8fb625
G_END_DECLS
Packit 8fb625
Packit 8fb625
#endif /* __BLUETOOTH_PAIRING_DIALOG_H */