Added value actions for common value types; drop down list is now correctly aligned

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@92 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2006-11-24 16:36:17 +00:00
parent edfe24a05f
commit 0a916f89bc
23 changed files with 268 additions and 66 deletions
+6
View File
@@ -57,6 +57,12 @@ wxPen DataViewer::borderPen(bool) const { return wxPen(); }
ValueViewer* DataViewer::focusedViewer() const { return nullptr; }
Context& DataViewer::getContext() const { return set->getContext(); }
Rotation DataViewer::getRotation() const {
StyleSheetP stylesheet = set->stylesheetFor(card);
StyleSheetSettings& ss = settings.stylesheetSettingsFor(*stylesheet);
return Rotation(ss.card_angle(), stylesheet->getCardRect(), ss.card_zoom());
}
// ----------------------------------------------------------------------------- : Setting data
void DataViewer::setCard(const CardP& card) {
+2
View File
@@ -52,6 +52,8 @@ class DataViewer : public SetView {
virtual ValueViewer* focusedViewer() const;
/// Get a script context to use for scripts in the viewers
Context& getContext() const;
/// The rotation to use
virtual Rotation getRotation() const;
// --------------------------------------------------- : Setting data
+1 -1
View File
@@ -58,8 +58,8 @@ class ValueViewer {
/// Convert this viewer to an editor, if possible
virtual ValueEditor* getEditor() { return 0; }
protected:
DataViewer& viewer; ///< Our parent object
protected:
StyleP styleP; ///< The style of this viewer
ValueP valueP; ///< The value we are currently viewing