Conversion to new ScriptableImage complete, this affected quite a bit, including the evil thumbnail thread;

Added StyleListener, so style changes are only propagated to interested viewers.

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@329 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-05-10 00:47:27 +00:00
parent 71adbf8545
commit 00b3e3a3cd
28 changed files with 282 additions and 531 deletions
+5
View File
@@ -22,6 +22,8 @@ class Context;
/// A viewer can generate an image of some values, usually a card.
class DataViewer : public SetView {
public:
DataViewer() : drawing(false) {}
// --------------------------------------------------- : Drawing
/// Draw the current (card/data) to the given dc
@@ -56,6 +58,8 @@ class DataViewer : public SetView {
virtual Rotation getRotation() const;
/// The card we are viewing
inline CardP getCard() const { return card; }
/// Invalidate and redraw (the area of) a single value viewer
virtual void redraw(const ValueViewer&) {}
// --------------------------------------------------- : Setting data
@@ -86,6 +90,7 @@ class DataViewer : public SetView {
vector<ValueViewerP> viewers; ///< The viewers for the different values in the data
CardP card; ///< The card that is currently displayed, if any
bool drawing; ///< Are we currently drawing?
public:
mutable StyleSheetP stylesheet; ///< Stylesheet being used
};