CellRendererText::CellRendererText() : CellRendererText(GTK_CELL_RENDERER_TEXT(gtk_cell_renderer_text_new()))
{ }
+ ComboBoxText::ComboBoxText() : ComboBoxText(GTK_COMBO_BOX(gtk_combo_box_new_text()))
+ { }
+
CheckButton::CheckButton(const char *label) : CheckButton(GTK_CHECK_BUTTON(gtk_check_button_new_with_label(label)))
{ }
using ui_box = struct _GtkBox;
using ui_button = struct _GtkButton;
using ui_checkbutton = struct _GtkCheckButton;
+using ui_combobox = struct _GtkComboBox;
+using ui_comboboxtext = ui_combobox;
using ui_cellrenderer = struct _GtkCellRenderer;
using ui_cellrenderertext = struct _GtkCellRendererText;
using ui_entry = struct _GtkEntry;
CheckButton(const char *label);
);
+ WRAP(ComboBox, Widget, ui_combobox,);
+
+ WRAP(ComboBoxText, ComboBox, ui_comboboxtext,
+ ComboBoxText();
+ );
+
WRAP(Entry, Widget, ui_entry,
Entry();
Entry(std::size_t max_length);
ui::Widget alignment = ui::Alignment( 0.0, 0.5, 0.0, 0.0 );
gtk_widget_show( alignment );
{
- ui::Widget combo = ui::Widget(gtk_combo_box_new_text());
+ ui::Widget combo = ui::ComboBoxText();
for ( StringArrayRange::Iterator i = values.first; i != values.last; ++i )
{
m_combo( 0 ),
m_nonModal( ApplyCaller( *this ) ),
m_type( type ){
- GtkComboBox* combo = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ GtkComboBox* combo = ui::ComboBoxText();
for ( ListAttributeType::const_iterator i = type.begin(); i != type.end(); ++i )
{
gtk_misc_set_alignment( GTK_MISC( label ), 1, 0.5 );
}
{
- dialog.game_combo.game_select = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ dialog.game_combo.game_select = ui::ComboBoxText();
gtk_combo_box_append_text( dialog.game_combo.game_select, globalGameComboConfiguration().basegame );
if ( globalGameComboConfiguration().known[0] != '\0' ) {
(GtkAttachOptions) ( 0 ), 0, 0 );
gtk_misc_set_alignment( GTK_MISC( label ), 1, 0.5 );
- GtkComboBox* combo = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ GtkComboBox* combo = ui::ComboBoxText();
gtk_combo_box_append_text( combo, globalMappingMode().sp_mapping_mode );
gtk_combo_box_append_text( combo, globalMappingMode().mp_mapping_mode );
(GtkAttachOptions)( 0 ), 0, 0 );
}
{
- GtkComboBox* combo = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ GtkComboBox* combo = ui::ComboBoxText();
g_signal_connect( G_OBJECT( combo ), "changed", G_CALLBACK( OnSelchangeComboColRow ), this );
AddDialogData( *combo, m_nRow );
}
{
- GtkComboBox* combo = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ GtkComboBox* combo = ui::ComboBoxText();
g_signal_connect( G_OBJECT( combo ), "changed", G_CALLBACK( OnSelchangeComboColRow ), this );
AddDialogData( *combo, m_nCol );
}
{
- GtkComboBox* combo = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ GtkComboBox* combo = ui::ComboBoxText();
#define D_ITEM( x ) if ( x >= mincols && ( !maxcols || x <= maxcols ) ) gtk_combo_box_append_text( combo, # x )
D_ITEM( 3 );
D_ITEM( 5 );
width = combo;
}
{
- GtkComboBox* combo = GTK_COMBO_BOX( gtk_combo_box_new_text() );
+ GtkComboBox* combo = ui::ComboBoxText();
#define D_ITEM( x ) if ( x >= minrows && ( !maxrows || x <= maxrows ) ) gtk_combo_box_append_text( combo, # x )
D_ITEM( 3 );
D_ITEM( 5 );