Merge revision 4785:4788 from trunk to ogl-es:
- IGUITable can now disable the active column. - IGUIElement::getElementFromPoint now virtual. - remove redundant includes. git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@4841 dfc29bdd-3216-0410-991c-e03cc46cb475master
parent
03b231db76
commit
2fc9d4403b
|
@ -7,6 +7,8 @@ Changes in ogl-es (not yet released - will be merged with trunk at some point)
|
|||
--------------------------
|
||||
Changes in 1.9 (not yet released)
|
||||
|
||||
- IGUITable can now disable the active column.
|
||||
- IGUIElement::getElementFromPoint now virtual
|
||||
- Fixed issue with wrongly enabled Z-writing for transparent shader materials. Thanks Hendu for this fix.
|
||||
- Allow more control over particle behavior. This also changed the default behavior.
|
||||
- ISceneNodeAnimators can now be disabled and paused.
|
||||
|
|
|
@ -239,14 +239,14 @@ public:
|
|||
\return The topmost GUI element at that point, or 0 if there are
|
||||
no candidate elements at this point.
|
||||
*/
|
||||
IGUIElement* getElementFromPoint(const core::position2d<s32>& point)
|
||||
virtual IGUIElement* getElementFromPoint(const core::position2d<s32>& point)
|
||||
{
|
||||
IGUIElement* target = 0;
|
||||
|
||||
// we have to search from back to front, because later children
|
||||
// might be drawn over the top of earlier ones.
|
||||
|
||||
core::list<IGUIElement*>::Iterator it = Children.getLast();
|
||||
core::list<IGUIElement*>::ConstIterator it = Children.getLast();
|
||||
|
||||
if (isVisible())
|
||||
{
|
||||
|
|
|
@ -6,9 +6,7 @@
|
|||
#define __I_GUI_TABLE_H_INCLUDED__
|
||||
|
||||
#include "IGUIElement.h"
|
||||
#include "irrTypes.h"
|
||||
#include "SColor.h"
|
||||
#include "IGUISkin.h"
|
||||
|
||||
namespace irr
|
||||
{
|
||||
|
@ -104,9 +102,9 @@ namespace gui
|
|||
virtual s32 getColumnCount() const = 0;
|
||||
|
||||
//! Makes a column active. This will trigger an ordering process.
|
||||
/** \param idx: The id of the column to make active.
|
||||
/** \param idx: The id of the column to make active or a negative number to make non active.
|
||||
\param doOrder: Do also the ordering which depending on mode for active column
|
||||
\return True if successful. */
|
||||
\return True when the column could be set active (aka - it did exist). */
|
||||
virtual bool setActiveColumn(s32 idx, bool doOrder=false) = 0;
|
||||
|
||||
//! Returns which header is currently active
|
||||
|
@ -190,10 +188,10 @@ namespace gui
|
|||
//! clears the table, deletes all items in the table
|
||||
virtual void clear() = 0;
|
||||
|
||||
//! Set flags, as defined in EGUI_TABLE_DRAW_FLAGS, which influence the layout
|
||||
//! Set flags, as defined in ::EGUI_TABLE_DRAW_FLAGS, which influence the layout
|
||||
virtual void setDrawFlags(s32 flags) = 0;
|
||||
|
||||
//! Get the flags, as defined in EGUI_TABLE_DRAW_FLAGS, which influence the layout
|
||||
//! Get the flags, as defined in ::EGUI_TABLE_DRAW_FLAGS, which influence the layout
|
||||
virtual s32 getDrawFlags() const = 0;
|
||||
};
|
||||
|
||||
|
|
|
@ -97,7 +97,7 @@ void CGUITable::addColumn(const wchar_t* caption, s32 columnIndex)
|
|||
}
|
||||
}
|
||||
|
||||
if (ActiveTab == -1)
|
||||
if (ActiveTab == -1 && Columns.size() == 1) // first column added - make it active automatically
|
||||
ActiveTab = 0;
|
||||
|
||||
recalculateWidths();
|
||||
|
@ -136,11 +136,10 @@ s32 CGUITable::getRowCount() const
|
|||
|
||||
bool CGUITable::setActiveColumn(s32 idx, bool doOrder )
|
||||
{
|
||||
if (idx < 0 || idx >= (s32)Columns.size())
|
||||
return false;
|
||||
if ( idx >= (s32)Columns.size() )
|
||||
idx = -1;
|
||||
|
||||
bool changed = (ActiveTab != idx);
|
||||
|
||||
ActiveTab = idx;
|
||||
if ( ActiveTab < 0 )
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue