mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-11 13:17:00 -04:00
Layout() always called when editor/viewer control changes size
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@145 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -58,6 +58,7 @@ ValueViewer* DataViewer::focusedViewer() const { return nullptr; }
|
||||
Context& DataViewer::getContext() const { return set->getContext(); }
|
||||
|
||||
Rotation DataViewer::getRotation() const {
|
||||
if (!stylesheet) stylesheet = set->stylesheet;
|
||||
StyleSheetSettings& ss = settings.stylesheetSettingsFor(*stylesheet);
|
||||
return Rotation(ss.card_angle(), stylesheet->getCardRect(), ss.card_zoom(), true);
|
||||
}
|
||||
@@ -71,6 +72,7 @@ void DataViewer::setCard(const CardP& card) {
|
||||
stylesheet = set->stylesheetFor(card);
|
||||
setStyles(stylesheet, stylesheet->card_style);
|
||||
setData(card->data);
|
||||
onChangeSize();
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------- : Viewers
|
||||
|
||||
Reference in New Issue
Block a user