mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-11 21:27:01 -04:00
Reverted resource references for combine_something, you can't use tool_image here, because on MSW that only works for .bmps'
Added dependency stuff to invalidate Choice images; Fixed 'duplicate' in symbol editor git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@197 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -143,6 +143,7 @@ TextValueAction* typing_action(const TextValueP& value, size_t start, size_t end
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------- : Event
|
||||
|
||||
String ScriptValueEvent::getName(bool) const {
|
||||
@@ -152,3 +153,12 @@ String ScriptValueEvent::getName(bool) const {
|
||||
void ScriptValueEvent::perform(bool) {
|
||||
assert(false); // this action is just an event, it should not be performed
|
||||
}
|
||||
|
||||
|
||||
String ScriptStyleEvent::getName(bool) const {
|
||||
assert(false); // this action is just an event, getName shouldn't be called
|
||||
throw InternalError(_("ScriptStyleEvent::getName"));
|
||||
}
|
||||
void ScriptStyleEvent::perform(bool) {
|
||||
assert(false); // this action is just an event, it should not be performed
|
||||
}
|
||||
|
||||
@@ -19,7 +19,9 @@
|
||||
#include <util/defaultable.hpp>
|
||||
|
||||
class Card;
|
||||
class StyleSheet;
|
||||
DECLARE_POINTER_TYPE(Value);
|
||||
DECLARE_POINTER_TYPE(Style);
|
||||
DECLARE_POINTER_TYPE(TextValue);
|
||||
DECLARE_POINTER_TYPE(ChoiceValue);
|
||||
DECLARE_POINTER_TYPE(ColorValue);
|
||||
@@ -87,5 +89,19 @@ class ScriptValueEvent : public Action {
|
||||
const Value* value; ///< The modified value
|
||||
};
|
||||
|
||||
/// Notification that a script caused a style to change
|
||||
class ScriptStyleEvent : public Action {
|
||||
public:
|
||||
inline ScriptStyleEvent(const StyleSheet* stylesheet, const Style* style)
|
||||
: stylesheet(stylesheet), style(style)
|
||||
{}
|
||||
|
||||
virtual String getName(bool to_undo) const;
|
||||
virtual void perform(bool to_undo);
|
||||
|
||||
const StyleSheet* stylesheet; ///< StyleSheet the style is for
|
||||
const Style* style; ///< The modified style
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------- : EOF
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user