added SymbolValueEditor + minor fixes

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@96 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2006-11-26 18:51:31 +00:00
parent 8dcda6fd93
commit e2701a646f
19 changed files with 104 additions and 37 deletions
+2
View File
@@ -43,6 +43,7 @@ void ActionStack::add(Action* action, bool allow_merge) {
void ActionStack::undo() {
assert(canUndo());
if (!canUndo()) return;
Action* action = undo_actions.back();
action->perform(true);
tellListeners(*action, true);
@@ -52,6 +53,7 @@ void ActionStack::undo() {
}
void ActionStack::redo() {
assert(canRedo());
if (!canRedo()) return;
Action* action = redo_actions.back();
action->perform(false);
tellListeners(*action, false);
+1 -1
View File
@@ -203,7 +203,7 @@ String Package::nameOut(const String& file) {
}
}
String Package::newFileName(const String& prefix, const String& suffix) {
FileName Package::newFileName(const String& prefix, const String& suffix) {
assert(wxThread::IsMain()); // Writing should only be done from the main thread
String name;
UInt infix = 0;
+1 -1
View File
@@ -98,7 +98,7 @@ class Package {
/// Creates a new, unique, filename with the specified prefix and suffix
/// for example newFileName("image/",".jpg") -> "image/1.jpg"
/// Returns the name of a temporary file that can be written to.
String newFileName(const String& prefix, const String& suffix);
FileName newFileName(const String& prefix, const String& suffix);
/// Signal that a file is still used by this package.
/// Must be called for files not opened using openOut/nameOut
+5 -1
View File
@@ -66,7 +66,11 @@ typedef unsigned int UInt;
#define nullptr 0
/// A string standing for a filename, has different behaviour when reading/writing
class FileName : public String {};
class FileName : public String {
public:
FileName() {}
FileName(const String& s) : String(s) {}
};
// ----------------------------------------------------------------------------- : EOF
#endif