2016-05-04 10:07:13 +00:00
|
|
|
#if defined(Hiro_TableView)
|
|
|
|
|
|
|
|
namespace hiro {
|
|
|
|
|
|
|
|
auto pTableViewColumn::construct() -> void {
|
|
|
|
@autoreleasepool {
|
2018-08-05 09:00:15 +00:00
|
|
|
if(auto tableView = _parent()) {
|
2016-05-04 10:07:13 +00:00
|
|
|
[tableView->cocoaView reloadColumns];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::destruct() -> void {
|
|
|
|
@autoreleasepool {
|
2018-08-05 09:00:15 +00:00
|
|
|
if(auto tableView = _parent()) {
|
2016-05-04 10:07:13 +00:00
|
|
|
[tableView->cocoaView reloadColumns];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setActive() -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setAlignment(Alignment alignment) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setBackgroundColor(Color color) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setEditable(bool editable) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setExpandable(bool expandable) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setFont(const Font& font) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setForegroundColor(Color color) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setHorizontalAlignment(double alignment) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setIcon(const image& icon) -> void {
|
2018-08-05 09:00:15 +00:00
|
|
|
//TODO
|
2016-05-04 10:07:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setResizable(bool resizable) -> void {
|
|
|
|
}
|
|
|
|
|
2018-08-05 09:00:15 +00:00
|
|
|
auto pTableViewColumn::setSorting(Sort sorting) -> void {
|
|
|
|
setText(state().text);
|
2016-05-04 10:07:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setText(const string& text) -> void {
|
|
|
|
@autoreleasepool {
|
2018-08-05 09:00:15 +00:00
|
|
|
if(auto parent = _parent()) {
|
|
|
|
string label = text;
|
|
|
|
if(state().sorting == Sort::Ascending ) label.append(" \u25b4");
|
|
|
|
if(state().sorting == Sort::Descending) label.append(" \u25be");
|
|
|
|
NSTableColumn* tableColumn = [[parent->cocoaView content] tableColumnWithIdentifier:[[NSNumber numberWithInteger:self().offset()] stringValue]];
|
|
|
|
[[tableColumn headerCell] setStringValue:[NSString stringWithUTF8STring:label]];
|
|
|
|
[[parent->cocoaView headerView] setNeedsDisplay:YES];
|
2016-05-04 10:07:13 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setVerticalAlignment(double alignment) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setVisible(bool visible) -> void {
|
|
|
|
}
|
|
|
|
|
|
|
|
auto pTableViewColumn::setWidth(signed width) -> void {
|
|
|
|
}
|
|
|
|
|
2018-08-05 09:00:15 +00:00
|
|
|
auto pTableViewColumn::_parent() -> maybe<pTableView&> {
|
Update to v106r59 release.
byuu says:
Changelog:
- fixed bug in Emulator::Game::Memory::operator bool()
- nall: renamed view<string> back to `string_view`
- nall:: implemented `array_view`
- Game Boy: split cartridge-specific input mappings (rumble,
accelerometer) to their own separate ports
- Game Boy: fixed MBC7 accelerometer x-axis
- icarus: Game Boy, Super Famicom, Mega Drive cores output internal
header game titles to heuristics manifests
- higan, icarus, hiro/gtk: improve viewport geometry configuration;
fixed higan crashing bug with XShm driver
- higan: connect Video::poll(),update() functionality
- hiro, ruby: several compilation / bugfixes, should get the macOS
port compiling again, hopefully [Sintendo]
- ruby/video/xshm: fix crashing bug on window resize
- a bit hacky; it's throwing BadAccess Xlib warnings, but they're
not fatal, so I am catching and ignoring them
- bsnes: removed Application::Windows::onModalChange hook that's no
longer needed [Screwtape]
2018-08-26 06:49:54 +00:00
|
|
|
if(auto parent = self().parentTableView()) {
|
2016-05-04 10:07:13 +00:00
|
|
|
if(auto self = parent->self()) return *self;
|
|
|
|
}
|
2018-08-05 09:00:15 +00:00
|
|
|
return {};
|
2016-05-04 10:07:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|