daily pastebin goal
60%
SHARE
TWEET

Untitled

a guest Sep 15th, 2012 30 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. diff -r 7c68ddce6561 datafiles/layouts/TabPage1.layout
  2. --- a/datafiles/layouts/TabPage1.layout Wed Sep 05 14:32:16 2012 +0200
  3. +++ b/datafiles/layouts/TabPage1.layout Sun Sep 16 06:35:07 2012 +0300
  4. @@ -21,7 +21,7 @@
  5.              <Property name="TooltipText" value="Switch active page to selected" />
  6.          </Window>
  7.  
  8. -        <Window name="PageList" type="TaharezLook/Listbox">
  9. +        <Window name="PageList" type="TaharezLook/ItemListbox">
  10.              <Property name="Area" value="{{0.55,0},{0.1,0},{0.95,0},{0.48,0}}" />
  11.              <Property name="TooltipText" value="A list of available tabs to experiment with" />
  12.          </Window>
  13. diff -r 7c68ddce6561 samples/TabControlDemo/Sample_TabControl.cpp
  14. --- a/samples/TabControlDemo/Sample_TabControl.cpp      Wed Sep 05 14:32:16 2012 +0200
  15. +++ b/samples/TabControlDemo/Sample_TabControl.cpp      Sun Sep 16 06:35:07 2012 +0300
  16. @@ -178,12 +178,12 @@
  17.      {
  18.          Window* root = System::getSingleton().getDefaultGUIContext().getRootWindow();
  19.          // Check if the windows exists
  20. -        Listbox* lbox = 0;
  21. +        ItemListbox* lbox = 0;
  22.          TabControl* tc = 0;
  23.  
  24.          if (root->isChild("Frame/TabControl/Page1/PageList"))
  25.          {
  26. -            lbox = static_cast<Listbox*>(root->getChild(
  27. +            lbox = static_cast<ItemListbox*>(root->getChild(
  28.                                               "Frame/TabControl/Page1/PageList"));
  29.          }
  30.  
  31. @@ -199,8 +199,10 @@
  32.  
  33.              for (size_t i = 0; i < tc->getTabCount(); i++)
  34.              {
  35. -                lbox->addItem(new MyListItem(
  36. -                                  tc->getTabContentsAtIndex(i)->getName()));
  37. +                ItemEntry* item = static_cast<ItemEntry*>(
  38. +                                      WindowManager::getSingleton().createWindow("TaharezLook/ListboxItem"));
  39. +                item->setText(tc->getTabContentsAtIndex(i)->getName());
  40. +                lbox->addItem(item);
  41.              }
  42.          }
  43.      }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top