Browse Source

Merge branch 'development' of https://github.com/GarageGames/Torque2D into development

Peter Robinson 5 years ago
parent
commit
d6e289363c

+ 1 - 3
editor/EditorConsole/EditorConsole.cs

@@ -40,7 +40,6 @@ function EditorConsole::create(%this)
 		TabComplete="0";
 		SinkAllKeyEvents="1";
 		UseSiblingScroller="1";
-		Text = "Hello World";
 	};
 	%this.guiPage.add(%this.consoleEntry);
 
@@ -59,7 +58,6 @@ function EditorConsole::create(%this)
 
 	%this.scroller = new GuiScrollCtrl()
 	{
-		Name="ConsoleScrollCtrl";
 		Profile=EditorCore.themes.scrollProfile;
 		ThumbProfile = EditorCore.themes.thumbProfile;
 		TrackProfile = EditorCore.themes.trackProfile;
@@ -78,7 +76,7 @@ function EditorConsole::create(%this)
 
 	%this.consoleLog = new GuiConsole()
 	{
-		Profile="GuiConsoleProfile";
+		Profile=EditorCore.themes.consoleProfile;
 		Position="0 0";
 		Extent="1024 738";
 		HorizSizing="width";

+ 14 - 5
editor/EditorCore/Themes/BaseTheme.cs

@@ -8,6 +8,7 @@ function BaseTheme::onAdd(%this)
 	%this.makeTabProfile();
 	%this.makeTextEditProfile();
 	%this.makeScrollProfile();
+	%this.makeConsoleProfile();
 }
 
 function BaseTheme::init(%this)
@@ -555,22 +556,30 @@ function BaseTheme::makeScrollProfile(%this)
 	%mainBorder = new GuiBorderProfile()
 	{
 		margin = 5;
-		padding = 20;
+		padding = 5;
 		border = 3;
 		borderColor = %this.color5;
 	};
 	%this.scrollProfile = new GuiControlProfile()
 	{
 			opaque = true;
-	    fillColor = %this.setAlpha(%this.color3, 100);
-			fillColorHL = %this.color3;
-			fillColorSL = %this.color4;
-			fillColorNA = %this.setAlpha(%this.color4, 80);
+	    fillColor = %this.setAlpha(%this.color2, 180);
 
 			borderDefault = %mainBorder;
 	};
 }
 
+function BaseTheme::makeConsoleProfile(%this)
+{
+	%this.consoleProfile = new GuiControlProfile()
+	{
+		fontType = %this.font;
+		fontColor = %this.color4; //Normal text
+		fontColorHL = %this.setAlpha(%this.color4, 140); //Warnings
+		fontColorNA = "255 0 0 255"; //Errors
+	};
+}
+
 function BaseTheme::adjustValue(%this, %color, %percent)
 {
 	%red = getWord(%color, 0);

+ 1 - 0
editor/EditorCore/Themes/ThemeManager.cs

@@ -91,6 +91,7 @@ function ThemeManager::activateTheme(%this, %theme)
 	%this.thumbProfile = %theme.thumbProfile;
 	%this.trackProfile = %theme.trackProfile;
 	%this.scrollArrowProfile = %theme.scrollArrowProfile;
+	%this.consoleProfile = %theme.consoleProfile;
 
 	%this.postEvent("ThemeChanged", %this);
 }

+ 0 - 2
engine/compilers/VisualStudio 2019/Torque 2D.vcxproj

@@ -413,7 +413,6 @@
     <ClCompile Include="..\..\source\gui\guiTextEditCtrl.cc" />
     <ClCompile Include="..\..\source\gui\guiTextEditSliderCtrl.cc" />
     <ClCompile Include="..\..\source\gui\guiTextListCtrl.cc" />
-    <ClCompile Include="..\..\source\gui\guiTickCtrl.cc" />
     <ClCompile Include="..\..\source\gui\guiTreeViewCtrl.cc" />
     <ClCompile Include="..\..\source\gui\guiTypes.cc" />
     <ClCompile Include="..\..\source\gui\language\lang.cc" />
@@ -921,7 +920,6 @@
     <ClInclude Include="..\..\source\gui\guiTextEditCtrl.h" />
     <ClInclude Include="..\..\source\gui\guiTextEditSliderCtrl.h" />
     <ClInclude Include="..\..\source\gui\guiTextListCtrl.h" />
-    <ClInclude Include="..\..\source\gui\guiTickCtrl.h" />
     <ClInclude Include="..\..\source\gui\guiTreeViewCtrl.h" />
     <ClInclude Include="..\..\source\gui\guiTypes.h" />
     <ClInclude Include="..\..\source\gui\language\lang.h" />

+ 0 - 6
engine/compilers/VisualStudio 2019/Torque 2D.vcxproj.filters

@@ -843,9 +843,6 @@
     <ClCompile Include="..\..\source\gui\guiTextListCtrl.cc">
       <Filter>gui</Filter>
     </ClCompile>
-    <ClCompile Include="..\..\source\gui\guiTickCtrl.cc">
-      <Filter>gui</Filter>
-    </ClCompile>
     <ClCompile Include="..\..\source\gui\guiTreeViewCtrl.cc">
       <Filter>gui</Filter>
     </ClCompile>
@@ -2118,9 +2115,6 @@
     <ClInclude Include="..\..\source\gui\guiTextListCtrl.h">
       <Filter>gui</Filter>
     </ClInclude>
-    <ClInclude Include="..\..\source\gui\guiTickCtrl.h">
-      <Filter>gui</Filter>
-    </ClInclude>
     <ClInclude Include="..\..\source\gui\guiTreeViewCtrl.h">
       <Filter>gui</Filter>
     </ClInclude>

+ 8 - 0
engine/source/2d/gui/guiSpriteCtrl.cc

@@ -152,6 +152,14 @@ void GuiSpriteCtrl::onSleep()
 
 //-----------------------------------------------------------------------------
 
+void GuiSpriteCtrl::processTick(void)
+{
+	// Update using tick period.
+	update(Tickable::smTickSec);
+}
+
+//-----------------------------------------------------------------------------
+
 bool GuiSpriteCtrl::setImage( const char* pImageAssetId, const U32 frame )
 {
     // Sanity!

+ 3 - 0
engine/source/2d/gui/guiSpriteCtrl.h

@@ -67,6 +67,9 @@ public:
 
 protected:
     virtual void onAnimationEnd( void );
+	virtual void processTick();
+	virtual void interpolateTick(F32 delta) {};
+	virtual void advanceTime(F32 timeDelta) {};
 
 protected:
     static bool setImage(void* obj, const char* data) { static_cast<GuiSpriteCtrl*>(obj)->setImage( data ); return false; }

+ 2 - 6
engine/source/gui/containers/guiAutoScrollCtrl.h

@@ -26,14 +26,10 @@
 #include "gui/guiControl.h"
 #endif
 
-#ifndef _GUITICKCTRL_H_
-#include "gui/guiTickCtrl.h"
-#endif
-
-class GuiAutoScrollCtrl : public GuiTickCtrl
+class GuiAutoScrollCtrl : public GuiControl
 {
 private:
-   typedef GuiTickCtrl Parent;
+   typedef GuiControl Parent;
    bool mScrolling;
    F32 mCurrentTime;
    F32 mStartDelay;

+ 1 - 5
engine/source/gui/containers/guiRolloutCtrl.h

@@ -34,11 +34,7 @@
 #include "gui/guiDefaultControlRender.h"
 #endif
 
-#ifndef _GUITICKCTRL_H_
-#include "gui/guiTickCtrl.h"
-#endif
-
-class GuiRolloutCtrl : public GuiTickCtrl
+class GuiRolloutCtrl : public GuiControl
 {
 private:
    typedef GuiControl Parent;

+ 3 - 3
engine/source/gui/editor/guiDebugger.cc

@@ -562,7 +562,7 @@ void DbgFileView::onMouseDown(const GuiEvent &event)
 {
    if (! mActive)
    {
-      Parent::onMouseDown(event);
+      Parent::onTouchDown(event);
       return;
    }
 
@@ -588,7 +588,7 @@ void DbgFileView::onMouseDown(const GuiEvent &event)
       else
       {
          Point2I prevSelected = mSelectedCell;
-         Parent::onMouseDown(event);
+         Parent::onTouchDown(event);
          mBlockStart= -1;
          mBlockEnd = -1;
 
@@ -620,7 +620,7 @@ void DbgFileView::onMouseDown(const GuiEvent &event)
    }
    else
    {
-      Parent::onMouseDown(event);
+      Parent::onTouchDown(event);
    }
 }
 

+ 0 - 4
engine/source/gui/editor/guiInspector.h

@@ -42,10 +42,6 @@
 #include "gui/guiDefaultControlRender.h"
 #endif
 
-#ifndef _GUITICKCTRL_H_
-#include "gui/guiTickCtrl.h"
-#endif
-
 #ifndef _GUISCROLLCTRL_H_
 #include "gui/containers/guiScrollCtrl.h"
 #endif

+ 1 - 1
engine/source/gui/editor/guiMenuBar.cc

@@ -1214,7 +1214,7 @@ bool GuiMenuTextListCtrl::onKeyDown(const GuiEvent &event)
 
 void GuiMenuTextListCtrl::onMouseDown(const GuiEvent &event)
 {
-   Parent::onMouseDown(event);
+   Parent::onTouchDown(event);
    mMenuBarCtrl->closeMenu();
 }
 

+ 2 - 5
engine/source/gui/editor/guiMenuBar.h

@@ -26,9 +26,6 @@
 #ifndef _GUITEXTLISTCTRL_H_
 #include "gui/guiTextListCtrl.h"
 #endif
-#ifndef _GUITICKCTRL_H_
-#include "gui/guiTickCtrl.h"
-#endif
 
 class GuiMenuBar;
 class GuiMenuTextListCtrl;
@@ -84,9 +81,9 @@ class GuiMenuTextListCtrl : public GuiTextListCtrl
 
 //------------------------------------------------------------------------------
 
-class GuiMenuBar : public GuiTickCtrl // DAW: Was: GuiControl
+class GuiMenuBar : public GuiControl
 {
-   typedef GuiTickCtrl Parent; // DAW: Was: GuiControl Parent;
+   typedef GuiControl Parent;
 public:
 
     struct Menu;

+ 11 - 107
engine/source/gui/guiArrayCtrl.cc

@@ -26,8 +26,6 @@
 #include "gui/containers/guiScrollCtrl.h"
 #include "gui/guiArrayCtrl.h"
 
-IMPLEMENT_CONOBJECT(GuiArrayCtrl);
-
 // -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- //
 
 GuiArrayCtrl::GuiArrayCtrl()
@@ -38,7 +36,6 @@ GuiArrayCtrl::GuiArrayCtrl()
    mSize = Point2I(5, 30);
    mSelectedCell.set(-1, -1);
    mMouseOverCell.set(-1, -1);
-   mHeaderDim.set(0, 0);
    mIsContainer = true;
 }
 
@@ -64,7 +61,7 @@ void GuiArrayCtrl::onSleep()
 void GuiArrayCtrl::setSize(Point2I newSize)
 {
    mSize = newSize;
-   Point2I newExtent(newSize.x * mCellSize.x + mHeaderDim.x, newSize.y * mCellSize.y + mHeaderDim.y);
+   Point2I newExtent(newSize.x * mCellSize.x, newSize.y * mCellSize.y);
 
    resize(mBounds.point, newExtent);
 }
@@ -135,46 +132,6 @@ void GuiArrayCtrl::scrollCellVisible(Point2I cell)
 
 // -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- //
 
-void GuiArrayCtrl::onRenderColumnHeaders(Point2I offset, Point2I parentOffset, Point2I headerDim)
-{
-   if (mProfile->mBorderDefault && *(mProfile->mBorderDefault->mBorder) > 0)
-   {
-      RectI cellR(offset.x + headerDim.x, parentOffset.y, mBounds.extent.x - headerDim.x, headerDim.y);
-      dglDrawRectFill(cellR, mProfile->mBorderDefault->mBorderColor[0]);
-   }
-}
-
-void GuiArrayCtrl::onRenderRowHeader(Point2I offset, Point2I parentOffset, Point2I headerDim, Point2I cell)
-{
-   ColorI color;
-   RectI cellR;
-   if (cell.x % 2)
-      color.set(255, 0, 0, 255);
-   else
-      color.set(0, 255, 0, 255);
-
-   cellR.point.set(parentOffset.x, offset.y);
-   cellR.extent.set(headerDim.x, mCellSize.y);
-   dglDrawRectFill(cellR, color);
-}
-
-void GuiArrayCtrl::onRenderCell(Point2I offset, Point2I cell, bool selected, bool mouseOver)
-{
-   ColorI color(255 * (cell.x % 2), 255 * (cell.y % 2), 255 * ((cell.x + cell.y) % 2), 255);
-   if (selected)
-   {
-      color.set(255, 0, 0, 255);
-   }
-   else if (mouseOver)
-   {
-      color.set(0, 0, 255, 255);
-   }
-
-   //draw the cell
-   RectI cellR(offset.x, offset.y, mCellSize.x, mCellSize.y);
-   dglDrawRectFill(cellR, color);
-}
-
 void GuiArrayCtrl::onRender(Point2I offset, const RectI &updateRect)
 {
    //make sure we have a parent
@@ -188,33 +145,6 @@ void GuiArrayCtrl::onRender(Point2I offset, const RectI &updateRect)
 
    Point2I parentOffset = parent->localToGlobalCoord(Point2I(0, 0));
 
-   //if we have column headings
-   if (mHeaderDim.y > 0)
-   {
-      headerClip.point.x =   parentOffset.x + mHeaderDim.x;
-      headerClip.point.y =   parentOffset.y;
-      headerClip.extent.x =  clipRect.extent.x;// - headerClip.point.x; // This seems to fix some strange problems with some Gui's, bug? -pw
-      headerClip.extent.y =  mHeaderDim.y;
-
-      if (headerClip.intersect(clipRect))
-      {
-         dglSetClipRect(headerClip);
-
-         //now render the header
-         onRenderColumnHeaders(offset, parentOffset, mHeaderDim);
-
-         clipRect.point.y = headerClip.point.y + headerClip.extent.y - 1;
-      }
-      offset.y += mHeaderDim.y;
-   }
-
-   //if we have row headings
-   if (mHeaderDim.x > 0)
-   {
-      clipRect.point.x = getMax(clipRect.point.x, parentOffset.x + mHeaderDim.x);
-      offset.x += mHeaderDim.x;
-   }
-
    //save the original for clipping the row headers
    RectI origClipRect = clipRect;
 
@@ -228,24 +158,6 @@ void GuiArrayCtrl::onRender(Point2I offset, const RectI &updateRect)
       if(j * mCellSize.y + offset.y >= updateRect.point.y + updateRect.extent.y)
          break;
 
-      //render the header
-      if (mHeaderDim.x > 0)
-      {
-         headerClip.point.x = parentOffset.x;
-         headerClip.extent.x = mHeaderDim.x;
-         headerClip.point.y = offset.y + j * mCellSize.y;
-         headerClip.extent.y = mCellSize.y;
-         if (headerClip.intersect(origClipRect))
-         {
-            dglSetClipRect(headerClip);
-
-            //render the row header
-            onRenderRowHeader(Point2I(0, offset.y + j * mCellSize.y),
-                              Point2I(parentOffset.x, offset.y + j * mCellSize.y),
-                              mHeaderDim, Point2I(0, j));
-         }
-      }
-
       //render the cells for the row
       for (i = 0; i < mSize.x; i++)
       {
@@ -277,7 +189,7 @@ void GuiArrayCtrl::onRender(Point2I offset, const RectI &updateRect)
    }
 }
 
-void GuiArrayCtrl::onMouseDown(const GuiEvent &event)
+void GuiArrayCtrl::onTouchDown(const GuiEvent &event)
 {
    if ( !mActive || !mAwake || !mVisible )
       return;
@@ -286,7 +198,6 @@ void GuiArrayCtrl::onMouseDown(const GuiEvent &event)
    Parent::onTouchDown(event);
 
    Point2I pt = globalToLocalCoord(event.mousePoint);
-   pt.x -= mHeaderDim.x; pt.y -= mHeaderDim.y;
    Point2I cell(
          (pt.x < 0 ? -1 : pt.x / mCellSize.x), 
          (pt.y < 0 ? -1 : pt.y / mCellSize.y)
@@ -307,55 +218,49 @@ void GuiArrayCtrl::onMouseDown(const GuiEvent &event)
    }
 }
 
-void GuiArrayCtrl::onMouseEnter(const GuiEvent &event)
+void GuiArrayCtrl::onTouchEnter(const GuiEvent &event)
 {
    Point2I pt = globalToLocalCoord(event.mousePoint);
-   pt.x -= mHeaderDim.x; pt.y -= mHeaderDim.y;
 
    //get the cell
    Point2I cell((pt.x < 0 ? -1 : pt.x / mCellSize.x), (pt.y < 0 ? -1 : pt.y / mCellSize.y));
    if (cell.x >= 0 && cell.x < mSize.x && cell.y >= 0 && cell.y < mSize.y)
    {
       mMouseOverCell = cell;
-      setUpdateRegion(Point2I(cell.x * mCellSize.x + mHeaderDim.x,
-                              cell.y * mCellSize.y + mHeaderDim.y), mCellSize );
+      setUpdateRegion(Point2I(cell.x * mCellSize.x, cell.y * mCellSize.y), mCellSize );
       onCellHighlighted(mMouseOverCell);
    }
 }
 
-void GuiArrayCtrl::onMouseLeave(const GuiEvent & /*event*/)
+void GuiArrayCtrl::onTouchLeave(const GuiEvent & /*event*/)
 {
-   setUpdateRegion(Point2I(mMouseOverCell.x * mCellSize.x + mHeaderDim.x,
-                           mMouseOverCell.y * mCellSize.y + mHeaderDim.y), mCellSize);
+   setUpdateRegion(Point2I(mMouseOverCell.x * mCellSize.x, mMouseOverCell.y * mCellSize.y), mCellSize);
    mMouseOverCell.set(-1,-1);
    onCellHighlighted(mMouseOverCell);
 }
 
-void GuiArrayCtrl::onMouseDragged(const GuiEvent &event)
+void GuiArrayCtrl::onTouchDragged(const GuiEvent &event)
 {
    // for the array control, the behaviour of onMouseDragged is the same
    // as on mouse moved - basically just recalc the currend mouse over cell
    // and set the update regions if necessary
-   GuiArrayCtrl::onMouseMove(event);
+   GuiArrayCtrl::onTouchMove(event);
 }
 
-void GuiArrayCtrl::onMouseMove(const GuiEvent &event)
+void GuiArrayCtrl::onTouchMove(const GuiEvent &event)
 {
    Point2I pt = globalToLocalCoord(event.mousePoint);
-   pt.x -= mHeaderDim.x; pt.y -= mHeaderDim.y;
    Point2I cell((pt.x < 0 ? -1 : pt.x / mCellSize.x), (pt.y < 0 ? -1 : pt.y / mCellSize.y));
    if (cell.x != mMouseOverCell.x || cell.y != mMouseOverCell.y)
    {
       if (mMouseOverCell.x != -1)
       {
-         setUpdateRegion(Point2I(mMouseOverCell.x * mCellSize.x + mHeaderDim.x,
-                           mMouseOverCell.y * mCellSize.y + mHeaderDim.y), mCellSize);
+         setUpdateRegion(Point2I(mMouseOverCell.x * mCellSize.x, mMouseOverCell.y * mCellSize.y), mCellSize);
       }
 
       if (cell.x >= 0 && cell.x < mSize.x && cell.y >= 0 && cell.y < mSize.y)
       {
-         setUpdateRegion(Point2I(cell.x * mCellSize.x + mHeaderDim.x,
-                           cell.y * mCellSize.y + mHeaderDim.y), mCellSize);
+         setUpdateRegion(Point2I(cell.x * mCellSize.x, cell.y * mCellSize.y), mCellSize);
          mMouseOverCell = cell;
       }
       else
@@ -434,7 +339,6 @@ void GuiArrayCtrl::onRightMouseDown(const GuiEvent &event)
    Parent::onRightMouseDown( event );
 
    Point2I pt = globalToLocalCoord( event.mousePoint );
-   pt.x -= mHeaderDim.x; pt.y -= mHeaderDim.y;
    Point2I cell((pt.x < 0 ? -1 : pt.x / mCellSize.x), (pt.y < 0 ? -1 : pt.y / mCellSize.y));
    if (cell.x >= 0 && cell.x < mSize.x && cell.y >= 0 && cell.y < mSize.y)
    {

+ 6 - 11
engine/source/gui/guiArrayCtrl.h

@@ -37,7 +37,6 @@ class GuiArrayCtrl : public GuiControl
 
 protected:
 
-   Point2I mHeaderDim;
    Point2I mSize;
    Point2I mCellSize;
    Point2I mSelectedCell;
@@ -51,7 +50,6 @@ protected:
 public:
 
    GuiArrayCtrl();
-   DECLARE_CONOBJECT(GuiArrayCtrl);
 
    bool onWake();
    void onSleep();
@@ -60,7 +58,6 @@ public:
    /// @{
    Point2I getSize() { return mSize; }
    virtual void setSize(Point2I size);
-   void setHeaderDim(const Point2I &dim) { mHeaderDim = dim; }
    void getScrollDimensions(S32 &cell_size, S32 &num_cells);
    /// @}
 
@@ -75,19 +72,17 @@ public:
 
    /// @name Rendering methods
    /// @{
-   virtual void onRenderColumnHeaders(Point2I offset, Point2I parentOffset, Point2I headerDim);
-   virtual void onRenderRowHeader(Point2I offset, Point2I parentOffset, Point2I headerDim, Point2I cell);
-   virtual void onRenderCell(Point2I offset, Point2I cell, bool selected, bool mouseOver);
+   virtual void onRenderCell(Point2I offset, Point2I cell, bool selected, bool mouseOver) = 0;
    void onRender(Point2I offset, const RectI &updateRect);
    /// @}
 
    /// @name Mouse input methods
    /// @{
-   void onMouseDown(const GuiEvent &event);
-   void onMouseMove(const GuiEvent &event);
-   void onMouseDragged(const GuiEvent &event);
-   void onMouseEnter(const GuiEvent &event);
-   void onMouseLeave(const GuiEvent &event);
+   void onTouchDown(const GuiEvent &event);
+   void onTouchMove(const GuiEvent &event);
+   void onTouchDragged(const GuiEvent &event);
+   void onTouchEnter(const GuiEvent &event);
+   void onTouchLeave(const GuiEvent &event);
    bool onKeyDown(const GuiEvent &event);
    void onRightMouseDown(const GuiEvent &event);
    /// @}

+ 2 - 2
engine/source/gui/guiConsole.cc

@@ -100,13 +100,13 @@ void GuiConsole::onPreRender()
       //resize the control
       resize(mBounds.point, Point2I(mCellSize.x, mCellSize.y * size));
 
-      //if the console was not scrolled, make the last entry visible
+      //if the console was scrolled to the bottom then make sure any new row is also visible
       if (scrolled)
          scrollCellVisible(Point2I(0,mSize.y - 1));
    }
 }
 
-void GuiConsole::onRenderCell(Point2I offset, Point2I cell, bool /*selected*/, bool /*mouseOver*/)
+void GuiConsole::onRenderCell(Point2I offset, Point2I cell, bool selected, bool mouseOver)
 {
    U32 size;
    ConsoleLogEntry *log;

+ 29 - 1
engine/source/gui/guiControl.h

@@ -51,6 +51,11 @@
 #ifndef _LANG_H_
 #include "gui/language/lang.h"
 #endif
+
+#ifndef _TICKABLE_H_
+#include "platform/Tickable.h"
+#endif
+
 class GuiCanvas;
 class GuiEditCtrl;
 
@@ -87,10 +92,28 @@ class GuiEditCtrl;
 ///
 /// @ref GUI has an overview of the GUI system.
 ///
+/// Tickable Information - taken from guiTickCtrl now retired.
+/// This Gui Control is designed to recieve update ticks at a constant interval.
+/// It was created to be the Parent class of a control which used a DynamicTexture
+/// along with a VectorField to create warping effects much like the ones found
+/// in visualization displays for iTunes or Winamp. Those displays are updated
+/// at the framerate frequency. This works fine for those effects, however for
+/// an application of the same type of effects for things like Gui transitions
+/// the framerate-driven update frequency is not desireable because it does not
+/// allow the developer to be able to have any idea of a consistant user-experience.
+///
+/// Enter the Tickable interface. This lets the Gui control, in this case, update
+/// the dynamic texture at a constant rate of once per tick, even though it gets
+/// rendered every frame, thus creating a framerate-independant update frequency
+/// so that the effects are at a consistant speed regardless of the specifics
+/// of the system the user is on. This means that the screen-transitions will
+/// occur in the same time on a machine getting 300fps in the Gui shell as a
+/// machine which gets 150fps in the Gui shell.
+/// @see Tickable
 ///
 /// @ingroup gui_group Gui System
 /// @{
-class GuiControl : public SimGroup
+class GuiControl : public SimGroup, public virtual Tickable
 {
 private:
    typedef SimGroup Parent;
@@ -696,6 +719,11 @@ public:
 
     void inspectPostApply();
     void inspectPreApply();
+
+protected:
+	virtual void interpolateTick(F32 delta) {};
+	virtual void processTick() {};
+	virtual void advanceTime(F32 timeDelta) {};
 };
 /// @}
 

+ 2 - 2
engine/source/gui/guiPopUpCtrl.cc

@@ -180,7 +180,7 @@ void GuiPopupTextListCtrl::onMouseDown(const GuiEvent &event)
 
 void GuiPopupTextListCtrl::onMouseUp(const GuiEvent &event)
 {
-   Parent::onMouseDown(event);
+   Parent::onTouchDown(event);
    mPopUpCtrl->closePopUp();
    Parent::onTouchUp(event);
 }
@@ -1532,7 +1532,7 @@ void GuiPopUpMenuCtrl::autoScroll()
       mSc->scrollByRegion(mScrollDir);
       mScrollCount -= 1;
    }
-   mTl->onMouseMove(mEventSave);
+   mTl->onTouchMove(mEventSave);
 }
 
 //------------------------------------------------------------------------------

+ 1 - 3
engine/source/gui/guiPopUpCtrlEx.cc

@@ -187,7 +187,6 @@ void GuiPopupTextListCtrlEx::onMouseUp(const GuiEvent &event)
         return;
 
    Point2I pt = globalToLocalCoord(event.mousePoint);
-   pt.x -= mHeaderDim.x; pt.y -= mHeaderDim.y;
    Point2I cell(
       (pt.x < 0 ? -1 : pt.x / mCellSize.x), 
       (pt.y < 0 ? -1 : pt.y / mCellSize.y)
@@ -207,10 +206,9 @@ void GuiPopupTextListCtrlEx::onMouseUp(const GuiEvent &event)
 void GuiPopupTextListCtrlEx::onMouseMove( const GuiEvent &event )
 {
    if( !mPopUpCtrl || !mPopUpCtrl->isMethod("onHotTrackItem") )
-      return Parent::onMouseMove( event );
+      return Parent::onTouchMove( event );
 
    Point2I pt = globalToLocalCoord(event.mousePoint);
-   pt.x -= mHeaderDim.x; pt.y -= mHeaderDim.y;
    Point2I cell( (pt.x < 0 ? -1 : pt.x / mCellSize.x), (pt.y < 0 ? -1 : pt.y / mCellSize.y) );
 
    // Within Bounds?

+ 1 - 1
engine/source/gui/guiTextListCtrl.cc

@@ -524,7 +524,7 @@ void GuiTextListCtrl::setSize(Point2I newSize)
       mCellSize.y = mFont->getHeight() + 2;
    }
 
-   Point2I newExtent( newSize.x * mCellSize.x + mHeaderDim.x, newSize.y * mCellSize.y + mHeaderDim.y );
+   Point2I newExtent( newSize.x * mCellSize.x, newSize.y * mCellSize.y);
    resize( mBounds.point, newExtent );
 }
 

+ 0 - 36
engine/source/gui/guiTickCtrl.cc

@@ -1,36 +0,0 @@
-//-----------------------------------------------------------------------------
-// Copyright (c) 2013 GarageGames, LLC
-//
-// Permission is hereby granted, free of charge, to any person obtaining a copy
-// of this software and associated documentation files (the "Software"), to
-// deal in the Software without restriction, including without limitation the
-// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
-// sell copies of the Software, and to permit persons to whom the Software is
-// furnished to do so, subject to the following conditions:
-//
-// The above copyright notice and this permission notice shall be included in
-// all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
-// IN THE SOFTWARE.
-//-----------------------------------------------------------------------------
-
-#include "guiTickCtrl.h"
-
-IMPLEMENT_CONOBJECT( GuiTickCtrl );
-
-//------------------------------------------------------------------------------
-
-ConsoleMethod( GuiTickCtrl, setProcessTicks, void, 2, 3, "( [tick = true] ) - This will set this object to either be processing ticks or not\n"
-              "@return No return value." )
-{
-   if( argc == 3 )
-      object->setProcessTicks( dAtob( argv[2] ) );
-   else
-      object->setProcessTicks();
-}

+ 0 - 65
engine/source/gui/guiTickCtrl.h

@@ -1,65 +0,0 @@
-//-----------------------------------------------------------------------------
-// Copyright (c) 2013 GarageGames, LLC
-//
-// Permission is hereby granted, free of charge, to any person obtaining a copy
-// of this software and associated documentation files (the "Software"), to
-// deal in the Software without restriction, including without limitation the
-// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
-// sell copies of the Software, and to permit persons to whom the Software is
-// furnished to do so, subject to the following conditions:
-//
-// The above copyright notice and this permission notice shall be included in
-// all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
-// IN THE SOFTWARE.
-//-----------------------------------------------------------------------------
-
-#ifndef _GUITICKCTRL_H_
-#define _GUITICKCTRL_H_
-
-#include "guiControl.h"
-#include "platform/Tickable.h"
-
-/// This Gui Control is designed to be subclassed and let people create controls
-/// which want to recieve update ticks at a constant interval. This class was
-/// created to be the Parent class of a control which used a DynamicTexture
-/// along with a VectorField to create warping effects much like the ones found
-/// in visualization displays for iTunes or Winamp. Those displays are updated
-/// at the framerate frequency. This works fine for those effects, however for
-/// an application of the same type of effects for things like Gui transitions
-/// the framerate-driven update frequency is not desireable because it does not
-/// allow the developer to be able to have any idea of a consistant user-experience.
-///
-/// Enter the Tickable interface. This lets the Gui control, in this case, update
-/// the dynamic texture at a constant rate of once per tick, even though it gets
-/// rendered every frame, thus creating a framerate-independant update frequency
-/// so that the effects are at a consistant speed regardless of the specifics
-/// of the system the user is on. This means that the screen-transitions will
-/// occur in the same time on a machine getting 300fps in the Gui shell as a
-/// machine which gets 150fps in the Gui shell.
-/// @see Tickable
-class GuiTickCtrl : public GuiControl, public virtual Tickable
-{
-   typedef GuiControl Parent;
-
-private:
-
-protected:
-
-   // So this can be instantiated and not be a pure virtual class
-   virtual void interpolateTick( F32 delta ) {};
-   virtual void processTick() {};
-   virtual void advanceTime( F32 timeDelta ) {};
-
-public:
-   DECLARE_CONOBJECT( GuiTickCtrl );
-};
-
-
-#endif

+ 6 - 6
engine/source/gui/guiTreeViewCtrl.cc

@@ -2238,7 +2238,7 @@ void GuiTreeViewCtrl::onMouseUp(const GuiEvent &event)
 
    if (mFlags.test(IsEditable))
    {
-      Parent::onMouseMove( event );
+      Parent::onTouchMove( event );
       if (mOldDragY != mMouseOverCell.y)
       {
 
@@ -2617,7 +2617,7 @@ void GuiTreeViewCtrl::onMouseDragged(const GuiEvent &event)
    if (mSelectedItems.size() == 0)
       return;
    Point2I pt = globalToLocalCoord(event.mousePoint);
-   Parent::onMouseMove(event);
+   Parent::onTouchMove(event);
    mouseLock();
    mMouseDragged = true;
    // whats our mDragMidPoint?
@@ -2704,7 +2704,7 @@ void GuiTreeViewCtrl::onMouseDown(const GuiEvent & event)
 {
    if( !mActive || !mAwake || !mVisible )
    {
-      Parent::onMouseDown(event);
+      Parent::onTouchDown(event);
       return;
    }
    if ( mProfile->mCanKeyFocus )
@@ -2879,7 +2879,7 @@ void GuiTreeViewCtrl::onMouseMove( const GuiEvent &event )
    if ( mMouseOverCell.y >= 0 && mVisibleItems.size() > mMouseOverCell.y)
       mVisibleItems[mMouseOverCell.y]->mState.clear( Item::MouseOverBmp | Item::MouseOverText );
 
-   Parent::onMouseMove( event );
+   Parent::onTouchMove( event );
 
    if ( mMouseOverCell.y >= 0 )
    {
@@ -2904,7 +2904,7 @@ void GuiTreeViewCtrl::onMouseMove( const GuiEvent &event )
 //------------------------------------------------------------------------------
 void GuiTreeViewCtrl::onMouseEnter( const GuiEvent &event )
 {
-   Parent::onMouseEnter( event );
+   Parent::onTouchEnter( event );
    onMouseMove( event );
 }
 
@@ -2915,7 +2915,7 @@ void GuiTreeViewCtrl::onMouseLeave( const GuiEvent &event )
    if ( mMouseOverCell.y >= 0 && mVisibleItems.size() > mMouseOverCell.y)
       mVisibleItems[mMouseOverCell.y]->mState.clear( Item::MouseOverBmp | Item::MouseOverText );
 
-   Parent::onMouseLeave( event );
+   Parent::onTouchLeave( event );
 }
 
 

+ 0 - 6
engine/source/platform/Tickable.h

@@ -77,12 +77,6 @@
 /// This is used to interpolate between 32ms ticks. The argument passed to
 /// interpolateTick is the time since the last call to processTick.
 ///
-/// This is an extremely powerful interface when used properly. An example of a class
-/// that properly uses this interface is GuiTickCtrl. The documentation for that
-/// class describes why it was created and why it was important that it use
-/// a consistant update frequency for its effects.
-/// @see GuiTickCtrl
-///
 /// @todo Support processBefore/After and move the GameBase processing over to use Tickable
 class Tickable
 {