Merge miscellaneous wxDataViewCtrl-related bug fixes
Make it possible to define custom renderers using text controls reacting to error presses in at least wxMSW and wxGTK. Closes https://github.com/wxWidgets/wxWidgets/pull/221
This commit is contained in:
@@ -180,6 +180,9 @@ public:
|
||||
// wxDVR_DEFAULT_ALIGNMENT.
|
||||
int GetEffectiveAlignment() const;
|
||||
|
||||
// Send wxEVT_DATAVIEW_ITEM_EDITING_STARTED event.
|
||||
void NotifyEditingStarted(const wxDataViewItem& item);
|
||||
|
||||
protected:
|
||||
// These methods are called from PrepareForItem() and should do whatever is
|
||||
// needed for the current platform to ensure that the item is rendered
|
||||
@@ -199,7 +202,7 @@ protected:
|
||||
wxString m_variantType;
|
||||
wxDataViewColumn *m_owner;
|
||||
wxWeakRef<wxWindow> m_editorCtrl;
|
||||
wxDataViewItem m_item; // for m_editorCtrl
|
||||
wxDataViewItem m_item; // Item being currently edited, if valid.
|
||||
|
||||
// internal utility, may be used anywhere the window associated with the
|
||||
// renderer is required
|
||||
|
@@ -3671,6 +3671,15 @@ protected:
|
||||
virtual bool TryParent(wxEvent& event), return DoTryApp(event); )
|
||||
#endif // WXWIN_COMPATIBILITY_2_8
|
||||
|
||||
// Overriding this method allows filtering the event handlers dynamically
|
||||
// connected to this object. If this method returns false, the handler is
|
||||
// not connected at all. If it returns true, it is connected using the
|
||||
// possibly modified fields of the given entry.
|
||||
virtual bool OnDynamicBind(wxDynamicEventTableEntry& WXUNUSED(entry))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
static const wxEventTable sm_eventTable;
|
||||
virtual const wxEventTable *GetEventTable() const;
|
||||
|
@@ -181,7 +181,10 @@ public:
|
||||
void OnSetFocus(wxFocusEvent& event);
|
||||
|
||||
// intercept WM_GETDLGCODE
|
||||
virtual WXLRESULT MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam);
|
||||
virtual bool MSWHandleMessage(WXLRESULT *result,
|
||||
WXUINT message,
|
||||
WXWPARAM wParam,
|
||||
WXLPARAM lParam);
|
||||
|
||||
virtual bool MSWShouldPreProcessMessage(WXMSG* pMsg);
|
||||
virtual WXDWORD MSWGetStyle(long style, WXDWORD *exstyle) const;
|
||||
|
@@ -14,6 +14,8 @@
|
||||
|
||||
#include "wx/settings.h" // solely for wxSystemColour
|
||||
|
||||
class WXDLLIMPEXP_FWD_CORE wxButton;
|
||||
|
||||
// if this is set to 1, we use deferred window sizing to reduce flicker when
|
||||
// resizing complicated window hierarchies, but this can in theory result in
|
||||
// different behaviour than the old code so we keep the possibility to use it
|
||||
@@ -534,6 +536,16 @@ public:
|
||||
virtual wxMenu* MSWFindMenuFromHMENU(WXHMENU hMenu);
|
||||
#endif // wxUSE_MENUS && !__WXUNIVERSAL__
|
||||
|
||||
// Return the default button for the TLW containing this window or NULL if
|
||||
// none.
|
||||
static wxButton* MSWGetDefaultButtonFor(wxWindow* win);
|
||||
|
||||
// Simulate a click on the given button if it is non-null, enabled and
|
||||
// shown.
|
||||
//
|
||||
// Return true if the button was clicked, false otherwise.
|
||||
static bool MSWClickButtonIfPossible(wxButton* btn);
|
||||
|
||||
protected:
|
||||
// this allows you to implement standard control borders without
|
||||
// repeating the code in different classes that are not derived from
|
||||
|
@@ -743,6 +743,11 @@ public:
|
||||
}
|
||||
|
||||
protected:
|
||||
// Override wxEvtHandler method to check for a common problem of binding
|
||||
// wxEVT_TEXT_ENTER to a control without wxTE_PROCESS_ENTER style, which is
|
||||
// never going to work.
|
||||
virtual bool OnDynamicBind(wxDynamicEventTableEntry& entry);
|
||||
|
||||
// override streambuf method
|
||||
#if wxHAS_TEXT_WINDOW_STREAM
|
||||
int overflow(int i) wxOVERRIDE;
|
||||
|
Reference in New Issue
Block a user