2016-05-04 10:07:13 +00:00
|
|
|
#if defined(Hiro_TableView)
|
2015-06-12 13:14:38 +00:00
|
|
|
|
|
|
|
namespace hiro {
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::construct() -> void {
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
if(auto grandparent = _grandparent()) {
|
|
|
|
grandparent->lock();
|
|
|
|
wchar_t text[] = L"";
|
|
|
|
LVCOLUMN lvColumn{0};
|
|
|
|
lvColumn.mask = LVCF_FMT | LVCF_TEXT | LVCF_SUBITEM;
|
|
|
|
lvColumn.fmt = LVCFMT_LEFT;
|
|
|
|
lvColumn.iSubItem = self().offset();
|
|
|
|
lvColumn.pszText = text;
|
|
|
|
ListView_InsertColumn(grandparent->hwnd, self().offset(), &lvColumn);
|
|
|
|
_setState();
|
|
|
|
grandparent->unlock();
|
|
|
|
}
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::destruct() -> void {
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
if(auto grandparent = _grandparent()) {
|
|
|
|
grandparent->lock();
|
|
|
|
ListView_DeleteColumn(grandparent->hwnd, self().offset());
|
|
|
|
grandparent->unlock();
|
|
|
|
}
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setActive() -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
//unsupported
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setAlignment(Alignment alignment) -> void {
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setBackgroundColor(Color color) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setEditable(bool editable) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
//unsupported
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setExpandable(bool expandable) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setForegroundColor(Color color) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setHorizontalAlignment(double alignment) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
_setState();
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setIcon(const image& icon) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
_setState();
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setResizable(bool resizable) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
_setState();
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setSortable(bool sortable) -> void {
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setText(const string& text) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
_setState();
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setVerticalAlignment(double alignment) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::setWidth(signed width) -> void {
|
2015-06-12 13:14:38 +00:00
|
|
|
_setState();
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::_grandparent() -> maybe<pTableView&> {
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
if(auto parent = _parent()) return parent->_parent();
|
|
|
|
return nothing;
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::_parent() -> maybe<pTableViewHeader&> {
|
|
|
|
if(auto parent = self().parentTableViewHeader()) {
|
2015-06-12 13:14:38 +00:00
|
|
|
if(auto self = parent->self()) return *self;
|
|
|
|
}
|
|
|
|
return nothing;
|
|
|
|
}
|
|
|
|
|
2016-05-04 10:07:13 +00:00
|
|
|
auto pTableViewColumn::_setState() -> void {
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
if(auto grandparent = _grandparent()) {
|
|
|
|
grandparent->lock();
|
|
|
|
grandparent->_setIcons();
|
2015-06-12 13:14:38 +00:00
|
|
|
utf16_t text(state().text);
|
|
|
|
LVCOLUMN lvColumn;
|
|
|
|
lvColumn.mask = LVCF_FMT | LVCF_SUBITEM | LVCF_TEXT | LVCF_WIDTH;
|
|
|
|
lvColumn.fmt = LVCFMT_CENTER;
|
|
|
|
lvColumn.iSubItem = self().offset();
|
|
|
|
lvColumn.iImage = self().offset();
|
|
|
|
lvColumn.pszText = text;
|
|
|
|
lvColumn.cx = _width;
|
|
|
|
if(state().horizontalAlignment < 0.333) lvColumn.fmt = LVCFMT_LEFT;
|
|
|
|
if(state().horizontalAlignment > 0.666) lvColumn.fmt = LVCFMT_RIGHT;
|
2016-01-07 08:14:33 +00:00
|
|
|
if(state().icon) lvColumn.mask |= LVCF_IMAGE;
|
2015-06-12 13:14:38 +00:00
|
|
|
if(!state().resizable) lvColumn.fmt |= LVCFMT_FIXED_WIDTH;
|
Update to v094r40 release.
byuu says:
Changelog:
- updated to newest hiro API
- SFC performance profile builds once again
- hiro: Qt port completed
Errata 1: the hiro/Qt target won't run tomoko just yet. Starts by
crashing inside InputSettings because hiro/Qt isn't forcefully selecting
the first item added to a ComboButton just yet. Even with a monkey patch
to get around that, the UI is incredibly unstable. Lots of geometry
calculation bugs, and a crash when you try and access certain folders in
the browser dialog. Lots of work left to be done there, sadly.
Errata 2: the hiro/Windows port has black backgrounds on all ListView
items. It's because I need to test for unassigned colors and grab the
default Windows brush colors in those cases.
Note: alternating row colors on multi-column ListView widgets is gone
now. Not a bug. May add it back later, but I'm not sure. It doesn't
interact nicely with per-cell background colors.
Things left to do:
First, I have to fix the Windows and Qt target bugs.
Next, I need to go through and revise the hiro API even more (nothing
too major.)
Next, I need to update icarus to use the new hiro API, and add support
for the SFC games database.
Next, I have to rewrite my TSV->BML cheat code tool.
Next, I need to post a final WIP of higan+icarus publicly and wait a few
days.
Next, I need to fix any bugs reported from the final WIP that I can.
Finally, I should be able to release v095.
2015-08-18 10:18:00 +00:00
|
|
|
ListView_SetColumn(grandparent->hwnd, self().offset(), &lvColumn);
|
|
|
|
grandparent->unlock();
|
2015-06-12 13:14:38 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|