Added wxPropertyGrid::DedicateKey(), which prevents specific key presses from being eaten by editor controls. This is useful for customizing keyboard navigation. Also added utility function wxPGFindInVector<>(), which is used in the new code, and also in some other places.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64562 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -340,6 +340,19 @@ WX_DECLARE_HASH_MAP_WITH_DECL(wxInt32,
|
||||
wxPGHashMapI2I,
|
||||
class WXDLLIMPEXP_PROPGRID);
|
||||
|
||||
// Utility to find if specific item is in a vector. Returns index to
|
||||
// the item, or wxNOT_FOUND if not present.
|
||||
template<typename CONTAINER, typename T>
|
||||
int wxPGFindInVector( CONTAINER vector, const T& item )
|
||||
{
|
||||
for ( unsigned int i=0; i<vector.size(); i++ )
|
||||
{
|
||||
if ( vector[i] == item )
|
||||
return (int) i;
|
||||
}
|
||||
return wxNOT_FOUND;
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------
|
||||
|
||||
enum wxPG_GETPROPERTYVALUES_FLAGS
|
||||
|
Reference in New Issue
Block a user