]> de.git.xonotic.org Git - xonotic/netradiant.git/blobdiff - radiant/surfacedialog.cpp
disabled 'detail' checkbox in q2 surface inspector
[xonotic/netradiant.git] / radiant / surfacedialog.cpp
index 89785bb7df1c7f04f3321c53a4cce7c16cfdf005..d8183fa5a121748b558b47bfc1918d03069a75e1 100644 (file)
@@ -1063,6 +1063,9 @@ GtkWindow* SurfaceInspector::BuildDialog()
                 g_object_set_data(G_OBJECT(check), "handler", gint_to_pointer(handler_id));
               }
             }
+
+            // not allowed to modify detail flag using Surface Inspector
+            gtk_widget_set_sensitive(GTK_WIDGET(m_contentFlags[27]), FALSE);
           }
         }
       }
@@ -1594,9 +1597,11 @@ void SurfaceInspector_Construct()
   GlobalPreferenceSystem().registerPreference("SI_SurfaceTexdef_Rotate", FloatImportStringCaller(g_si_globals.rotate), FloatExportStringCaller(g_si_globals.rotate));
   GlobalPreferenceSystem().registerPreference("SnapTToGrid", BoolImportStringCaller(g_si_globals.m_bSnapTToGrid), BoolExportStringCaller(g_si_globals.m_bSnapTToGrid));
 
-  GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, SurfaceInspector_SelectionChanged>());
-  Brush_addTextureChangedCallback(FreeCaller<SurfaceInspector_updateSelection>());
-  Patch_addTextureChangedCallback(FreeCaller<SurfaceInspector_updateSelection>());
+  typedef FreeCaller1<const Selectable&, SurfaceInspector_SelectionChanged> SurfaceInspectorSelectionChangedCaller;
+  GlobalSelectionSystem().addSelectionChangeCallback(SurfaceInspectorSelectionChangedCaller());
+  typedef FreeCaller<SurfaceInspector_updateSelection> SurfaceInspectorUpdateSelectionCaller;
+  Brush_addTextureChangedCallback(SurfaceInspectorUpdateSelectionCaller());
+  Patch_addTextureChangedCallback(SurfaceInspectorUpdateSelectionCaller());
 
   SurfaceInspector_registerPreferencesPage();
 }