]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - radiant/undo.cpp
- Weird shiftvalues are now hidden to the user, shiftvalues will
[xonotic/netradiant.git] / radiant / undo.cpp
index 5a15d34e45d0a68e4eeafc4b583387883dc5d024..aa75d950e27e61f415963dbfa624c0b5bbeef581 100644 (file)
@@ -60,7 +60,7 @@ public:
 
 class RadiantUndoSystem : public UndoSystem
 {
-  static const int MAX_UNDO_LEVELS = 1024;
+  INTEGER_CONSTANT(MAX_UNDO_LEVELS, 1024);
 
   class Snapshot
   {
@@ -295,9 +295,9 @@ public:
   }
   void setLevels(std::size_t levels)
   {
-    if(levels > MAX_UNDO_LEVELS)
+    if(levels > MAX_UNDO_LEVELS())
     {
-      levels = MAX_UNDO_LEVELS;
+      levels = MAX_UNDO_LEVELS();
     }
 
     while(m_undo_stack.size() > levels)
@@ -467,7 +467,7 @@ typedef ConstReferenceCaller1<RadiantUndoSystem, const IntImportCallback&, UndoL
 
 void Undo_constructPreferences(RadiantUndoSystem& undo, PreferencesPage& page)
 {
-  page.appendSpinner("Undo Queue Size", 64, 0, 1024, UndoLevelsImportCaller(undo), UndoLevelsExportCaller(undo));
+  page.appendSpinner("Undo Queue Size", 64, 0, 1024, IntImportCallback(UndoLevelsImportCaller(undo)), IntExportCallback(UndoLevelsExportCaller(undo)));
 }
 void Undo_constructPage(RadiantUndoSystem& undo, PreferenceGroup& group)
 {