History log of /haiku/src/kits/interface/GridLayout.cpp
Revision Date Author Comments
# 50e2057d 27-Dec-2014 Puck Meerburg <puck@puckipedia.nl>

BGridLayout: fix reversal of parameters.

CID 1210907.

Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>


# 814393e6 14-Apr-2015 Michael Lotz <mmlr@mlotz.ch>

BGridLayout: Fix leak of grid.


# 539dc1bc 02-Dec-2014 John Scipione <jscipione@gmail.com>

A bunch of style fixes

No functional changes intended


# b781fcec 15-Jul-2013 Murai Takashi <tmurai01@gmail.com>

GridLayout.cpp: use delete[] instead of delete. Fixes #9875.

Signed-off-by: Matt Madia <mattmadia@gmail.com>


# e724b26f 08-Jul-2013 John Scipione <jscipione@gmail.com>

Remove enum elaborated type specifier

...from orientation params. Elaborated type specifiers are not needed
for C++ code and removing them makes doxygen happy. Verified working
on both gcc2h and gcc4h builds.


# 53617d36 05-Nov-2011 Alex Wilson <yourpalal2@gmail.com>

Override a bunch of methods in layout related classes for FBC stability.

* Especially made sure to override archiving methods, since these are called rarely, so the cost is very minimal
* Otherwise, the closer a class is to a base class, the more likely I was to give it all the overrides.


# 8151838e 02-Nov-2011 Alex Wilson <yourpalal2@gmail.com>

Add FBC padding to all (I think..) of the visible Layout related classes.


# a851b3ad 31-Oct-2011 Alex Wilson <yourpalal2@gmail.com>

Add Perform() methods to all the layout-related classes that needed them.


# 6648dd3c 07-Jun-2011 Alex Wilson <yourpalal2@gmail.com>

* Add new spacing/inset constants for the layout API. For now, leave B_USE_DEFAULT_SPACING, but this will go soon.
* Rename BControlLook::ComposeItemSpacing() to ComposeSpacing(), and extend it to handle the new constants.
* Adjust users of BControlLook::ComposeItemSpacing() accordingly.
* part of #7447


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42025 a95241bf-73f2-0310-859d-f6bbb57e9c96


# de667551 14-Apr-2011 Alex Wilson <yourpalal2@gmail.com>

Add a new layouter 'CollapsingLayouter', which is used by BTwoDimensionalLayout to collapse empty rows or columns. Update BGridLayout so that empty rows/columns are given min/max constraints of B_SIZE_UNSET by default, which allows them to be collapsed. Fixes #6979


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41252 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 24a77ea0 08-Jan-2011 Axel Dörfler <axeld@pinc-software.de>

* Added ItemAt() method that accepts column and row.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40154 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 82ab3167 02-Sep-2010 Alex Wilson <yourpalal2@gmail.com>

Add default spacing for Layouts (#5614)
* introduce B_USE_DEFAULT_SPACING, which works somewhat like B_SIZE_UNSET and B_ALIGN_HORIZONTAL_UNSET
* introduce static float BControlLook::ComposeItemSpacing(float spacing), which checks uses be_control_look->DefaultItemSpacing().
* modify layouts to use BControlLook::ComposeItemSpacing() in SetInsets and SetSpacing methods.
* default insets are still 0, 0, 0, 0, but can be set to default spacing by passing B_USE_DEFAULT_SPACING
* I've found two regressions, patches incoming, please report others on #5614.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38512 a95241bf-73f2-0310-859d-f6bbb57e9c96


# afe949d2 07-Aug-2010 Alex Wilson <yourpalal2@gmail.com>

Fix incorrect initialization of boolean in BGridLayout::ItemRemoved() that lead to unreachable code, fixes CID 58.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37966 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6829d417 29-Jul-2010 Alex Wilson <yourpalal2@gmail.com>

Update BLayout::ItemAdded() and BLayout::ItemRemoved() to take an int32 index parameter, and ItemAdded() to return a bool indicating success or failure. Update BLayout::AddItem() to take the result of ItemAdded() into account. Also update BLayout::AllUnarchived() to take this into account. In either situation, if ItemAdded() returns false, the item does not get added to the layout. Removed various TODOs about code that could be removed once this change was made. In BSplitLayout, an item's LayoutData was lazy-initialized, but would always be created during ItemAdded(). Now we create the LayoutData explicitly, so that we can catch failed memory allocations. Closes #5524.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37817 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4a254e4d 27-Jul-2010 Alex Wilson <yourpalal2@gmail.com>

Generally, clean up new archiving constant names & strings to be consistent in all classes. Modify archiving constants to be const char* const (thanks Ingo). Also modify archiving in many classes to use less fields by storing more data in arrays and structs. The common min, max, and preferred sizes, for example are always stored in an array now. In BTwoDimensionalLayout and BSplitLayout, the insets are archived in a BRect. Also fixed a typo in BGridLayout which caused column info to be incorrect during archival.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37777 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d1535a45 16-Jul-2010 Ingo Weinhold <ingo_weinhold@gmx.de>

Patch by Alex Wilson:
* Implemented archiving/unarchiving support.
* Coding style cleanup (some more by myself).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37542 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c4945a42 25-Apr-2009 Ingo Weinhold <ingo_weinhold@gmx.de>

Added Count{Columns,Rows}().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30399 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 18cd67c7 22-Jan-2009 Michael Lotz <mmlr@mlotz.ch>

Add missing headers (malloc/free, string functions, memcpy, etc. undeclared).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28982 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fa83a2a1 22-Jun-2008 Rene Gollent <anevilyak@gmail.com>

These files were in CR/LF newline format for some reason.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26084 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d2bb3c43 27-Sep-2007 Ingo Weinhold <ingo_weinhold@gmx.de>

The new row/column info items were not added, so that setting column or row
properties (like the weight or min/max) would be ignored, besides memory
being leaked.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22336 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5df726a4 01-Feb-2007 Ingo Weinhold <ingo_weinhold@gmx.de>

Fixed infinite recursion. Discovered by Ryan.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20027 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3ec18e87 17-Sep-2006 Marcus Overhagen <marcusoverhagen@gmail.com>

various GCC 4 build fixes


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18875 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9ecf9d1c 26-Aug-2006 Ingo Weinhold <ingo_weinhold@gmx.de>

Merge from layout management branch.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18649 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 50e2057db04e8ed0d98982462fe0fb56195cdc6a 27-Dec-2014 Puck Meerburg <puck@puckipedia.nl>

BGridLayout: fix reversal of parameters.

CID 1210907.

Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>


# 814393e641b56d315baa42b5c61112630762f2ac 14-Apr-2015 Michael Lotz <mmlr@mlotz.ch>

BGridLayout: Fix leak of grid.


# 539dc1bc53a60fc507d1d5b82e872030f0b06e2f 02-Dec-2014 John Scipione <jscipione@gmail.com>

A bunch of style fixes

No functional changes intended


# b781fcec00d2e12b154f63b0b95ba81af0092d00 15-Jul-2013 Murai Takashi <tmurai01@gmail.com>

GridLayout.cpp: use delete[] instead of delete. Fixes #9875.

Signed-off-by: Matt Madia <mattmadia@gmail.com>


# e724b26f23ad0df100a47f8d913bcdb3d54267df 08-Jul-2013 John Scipione <jscipione@gmail.com>

Remove enum elaborated type specifier

...from orientation params. Elaborated type specifiers are not needed
for C++ code and removing them makes doxygen happy. Verified working
on both gcc2h and gcc4h builds.


# 53617d366d1729716cc1e2764feb4a734b65b9f0 05-Nov-2011 Alex Wilson <yourpalal2@gmail.com>

Override a bunch of methods in layout related classes for FBC stability.

* Especially made sure to override archiving methods, since these are called rarely, so the cost is very minimal
* Otherwise, the closer a class is to a base class, the more likely I was to give it all the overrides.


# 8151838e3892d0a18d89d73e2cc37e1f5d01264d 02-Nov-2011 Alex Wilson <yourpalal2@gmail.com>

Add FBC padding to all (I think..) of the visible Layout related classes.


# a851b3ad543ebaebc18589b959c01ccaaf35202f 31-Oct-2011 Alex Wilson <yourpalal2@gmail.com>

Add Perform() methods to all the layout-related classes that needed them.


# 6648dd3cf1597c4fcae16fcfa76270f3acda90b6 07-Jun-2011 Alex Wilson <yourpalal2@gmail.com>

* Add new spacing/inset constants for the layout API. For now, leave B_USE_DEFAULT_SPACING, but this will go soon.
* Rename BControlLook::ComposeItemSpacing() to ComposeSpacing(), and extend it to handle the new constants.
* Adjust users of BControlLook::ComposeItemSpacing() accordingly.
* part of #7447


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42025 a95241bf-73f2-0310-859d-f6bbb57e9c96


# de667551ce1c18738c555d92e8b3ec3e1ff86fb5 14-Apr-2011 Alex Wilson <yourpalal2@gmail.com>

Add a new layouter 'CollapsingLayouter', which is used by BTwoDimensionalLayout to collapse empty rows or columns. Update BGridLayout so that empty rows/columns are given min/max constraints of B_SIZE_UNSET by default, which allows them to be collapsed. Fixes #6979


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41252 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 24a77ea0bee4f9b74b0f7f3839b13bb39e932504 08-Jan-2011 Axel Dörfler <axeld@pinc-software.de>

* Added ItemAt() method that accepts column and row.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40154 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 82ab3167232c5c8ee53e684eddc83dc7cb60f1cc 02-Sep-2010 Alex Wilson <yourpalal2@gmail.com>

Add default spacing for Layouts (#5614)
* introduce B_USE_DEFAULT_SPACING, which works somewhat like B_SIZE_UNSET and B_ALIGN_HORIZONTAL_UNSET
* introduce static float BControlLook::ComposeItemSpacing(float spacing), which checks uses be_control_look->DefaultItemSpacing().
* modify layouts to use BControlLook::ComposeItemSpacing() in SetInsets and SetSpacing methods.
* default insets are still 0, 0, 0, 0, but can be set to default spacing by passing B_USE_DEFAULT_SPACING
* I've found two regressions, patches incoming, please report others on #5614.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38512 a95241bf-73f2-0310-859d-f6bbb57e9c96


# afe949d2f1de66b53c6038daed07b93f3e895de0 07-Aug-2010 Alex Wilson <yourpalal2@gmail.com>

Fix incorrect initialization of boolean in BGridLayout::ItemRemoved() that lead to unreachable code, fixes CID 58.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37966 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6829d4174ba57d752c8d470a55789112db477daf 29-Jul-2010 Alex Wilson <yourpalal2@gmail.com>

Update BLayout::ItemAdded() and BLayout::ItemRemoved() to take an int32 index parameter, and ItemAdded() to return a bool indicating success or failure. Update BLayout::AddItem() to take the result of ItemAdded() into account. Also update BLayout::AllUnarchived() to take this into account. In either situation, if ItemAdded() returns false, the item does not get added to the layout. Removed various TODOs about code that could be removed once this change was made. In BSplitLayout, an item's LayoutData was lazy-initialized, but would always be created during ItemAdded(). Now we create the LayoutData explicitly, so that we can catch failed memory allocations. Closes #5524.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37817 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4a254e4ddbb0aaeb909ecd68a8442c4302618050 27-Jul-2010 Alex Wilson <yourpalal2@gmail.com>

Generally, clean up new archiving constant names & strings to be consistent in all classes. Modify archiving constants to be const char* const (thanks Ingo). Also modify archiving in many classes to use less fields by storing more data in arrays and structs. The common min, max, and preferred sizes, for example are always stored in an array now. In BTwoDimensionalLayout and BSplitLayout, the insets are archived in a BRect. Also fixed a typo in BGridLayout which caused column info to be incorrect during archival.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37777 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d1535a45df40b867c0acfd08c97e4ec80137ab33 16-Jul-2010 Ingo Weinhold <ingo_weinhold@gmx.de>

Patch by Alex Wilson:
* Implemented archiving/unarchiving support.
* Coding style cleanup (some more by myself).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37542 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c4945a424ba3dcfa2bf3ad3e93ec5ae975f732c5 25-Apr-2009 Ingo Weinhold <ingo_weinhold@gmx.de>

Added Count{Columns,Rows}().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30399 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 18cd67c76072f825c4a7ba58414771d47fd1bfa2 22-Jan-2009 Michael Lotz <mmlr@mlotz.ch>

Add missing headers (malloc/free, string functions, memcpy, etc. undeclared).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28982 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fa83a2a121e37fe79a946b1e609e41401b160a26 22-Jun-2008 Rene Gollent <anevilyak@gmail.com>

These files were in CR/LF newline format for some reason.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26084 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d2bb3c435049b78132683c4de6e6baa1e292285d 27-Sep-2007 Ingo Weinhold <ingo_weinhold@gmx.de>

The new row/column info items were not added, so that setting column or row
properties (like the weight or min/max) would be ignored, besides memory
being leaked.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22336 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5df726a4037c9b7a6d7ccb6ec7438ef4e6763a11 01-Feb-2007 Ingo Weinhold <ingo_weinhold@gmx.de>

Fixed infinite recursion. Discovered by Ryan.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20027 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3ec18e87d6cfa48715a6ed10bcd03858d832093b 17-Sep-2006 Marcus Overhagen <marcusoverhagen@gmail.com>

various GCC 4 build fixes


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18875 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9ecf9d1c1d4888d341a6eac72112c72d1ae3a4cb 26-Aug-2006 Ingo Weinhold <ingo_weinhold@gmx.de>

Merge from layout management branch.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18649 a95241bf-73f2-0310-859d-f6bbb57e9c96