bool CanUndo() const;
bool CanRedo() const;
void SelectAll();
- bool IsEditable() const { return !HasFlag(wxCB_READONLY); }
+ bool IsEditable() const ;
bool HasSelection() const ;
// implementation
bool CanUndo() const;
bool CanRedo() const;
void SelectAll();
- bool IsEditable() const { return !HasFlag(wxCB_READONLY); }
+ bool IsEditable() const ;
bool HasSelection() const ;
// implementation
void wxComboBox::SelectAll()
{
- Select(0, GetLastPosition());
+ SetSelection(0, GetLastPosition());
}
bool wxComboBox::CanUndo() const
{
if (IsEditable())
{
+#ifdef __WXGTK20__
GtkEditable *editable = GTK_EDITABLE(GTK_COMBO(m_widget)->entry);
+ gint start, end;
+ gtk_editable_get_selection_bounds(editable, & start, & end);
+ *from = start;
+ *to = end;
+#else
*from = (long) editable->selection_start_pos;
*to = (long) editable->selection_end_pos;
+#endif
}
}
void wxComboBox::SelectAll()
{
- Select(0, GetLastPosition());
+ SetSelection(0, GetLastPosition());
}
bool wxComboBox::CanUndo() const
{
if (IsEditable())
{
+#ifdef __WXGTK20__
GtkEditable *editable = GTK_EDITABLE(GTK_COMBO(m_widget)->entry);
+ gint start, end;
+ gtk_editable_get_selection_bounds(editable, & start, & end);
+ *from = start;
+ *to = end;
+#else
*from = (long) editable->selection_start_pos;
*to = (long) editable->selection_end_pos;
+#endif
}
}