This variable could then be used in a command like this:
<pre>[arghrad] "[MapFile]"</pre>
+Entity: option to filter non-world entities (e.g. not func_group or func_static)
+Rotate Tool: if more than one object is selected, with different local orientations, use parent-space rotation pivot instead of local-space
Texture Browser: add a way to make large texture sets more manageable - shaderlist.txt was previously used this way
Brush: MMB+ctrl to paint texture on whole brush/patch.
Camera: add alternative highlighting styles (used to be J).
}
};
-class filter_face_shader_substring : public FaceFilter
+class filter_face_shader_prefix : public FaceFilter
{
- const char* m_shader;
+ const char* m_prefix;
public:
- filter_face_shader_substring(const char* shader) : m_shader(shader)
+ filter_face_shader_prefix(const char* prefix) : m_prefix(prefix)
{
}
bool filter(const Face& face) const
{
- return shader_equal_n(face.GetShader(), m_shader, strlen(m_shader));
+ return shader_equal_n(face.GetShader(), m_prefix, strlen(m_prefix));
}
};
filter_face_shader g_filter_face_caulk_ja("textures/system/caulk");
filter_brush_all_faces g_filter_brush_caulk_ja(&g_filter_face_caulk_ja);
-filter_face_shader_substring g_filter_face_liquids("textures/liquids/");
+filter_face_shader_prefix g_filter_face_liquids("textures/liquids/");
filter_brush_any_face g_filter_brush_liquids(&g_filter_face_liquids);
filter_face_shader g_filter_face_hint("textures/common/hint");
g_entityInspector_windowConstructed = true;
EntityClassList_fill();
- GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, EntityInspector_selectionChanged>());
+ typedef FreeCaller1<const Selectable&, EntityInspector_selectionChanged> EntityInspectorSelectionChangedCaller;
+ GlobalSelectionSystem().addSelectionChangeCallback(EntityInspectorSelectionChangedCaller());
GlobalEntityCreator().setKeyValueChangedFunc(EntityInspector_keyValueChanged);
// hack
GlobalPreferenceSystem().registerPreference("EntityInfoDlg", WindowPositionTrackerImportStringCaller(getEntityList().m_positionTracker), WindowPositionTrackerExportStringCaller(getEntityList().m_positionTracker));
- GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, EntityList_SelectionChanged>());
+ typedef FreeCaller1<const Selectable&, EntityList_SelectionChanged> EntityListSelectionChangedCaller;
+ GlobalSelectionSystem().addSelectionChangeCallback(EntityListSelectionChangedCaller());
}
void EntityList_Destroy()
{
Patch_registerCommands();
XYShow_registerCommands();
- GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, ComponentMode_SelectionChanged>());
+ typedef FreeCaller1<const Selectable&, ComponentMode_SelectionChanged> ComponentModeSelectionChangedCaller;
+ GlobalSelectionSystem().addSelectionChangeCallback(ComponentModeSelectionChangedCaller());
GlobalPreferenceSystem().registerPreference("DetachableMenus", BoolImportStringCaller(g_Layout_enableDetachableMenus.m_latched), BoolExportStringCaller(g_Layout_enableDetachableMenus.m_latched));
GlobalPreferenceSystem().registerPreference("PatchToolBar", BoolImportStringCaller(g_Layout_enablePatchToolbar.m_latched), BoolExportStringCaller(g_Layout_enablePatchToolbar.m_latched));
GlobalPreferenceSystem().registerPreference("SI_PatchTexdef_Shift2", FloatImportStringCaller(g_pi_globals.shift[1]), FloatExportStringCaller(g_pi_globals.shift[1]));
GlobalPreferenceSystem().registerPreference("SI_PatchTexdef_Rotate", FloatImportStringCaller(g_pi_globals.rotate), FloatExportStringCaller(g_pi_globals.rotate));
- GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, PatchInspector_SelectionChanged>());
- Patch_addTextureChangedCallback(FreeCaller<PatchInspector_queueDraw>());
+ typedef FreeCaller1<const Selectable&, PatchInspector_SelectionChanged> PatchInspectorSelectionChangedCaller;
+ GlobalSelectionSystem().addSelectionChangeCallback(PatchInspectorSelectionChangedCaller());
+ typedef FreeCaller<PatchInspector_queueDraw> PatchInspectorQueueDrawCaller;
+ Patch_addTextureChangedCallback(PatchInspectorQueueDrawCaller());
}
void PatchInspector_Destroy()
{
}
// update the workzone to the current selection
-void UpdateWorkzone_ForSelection(const Selectable& selectable)
+void UpdateWorkzone_ForSelectionChanged(const Selectable& selectable)
{
if(selectable.isSelected())
{
void Selection_construct()
{
- GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, SceneSelectionChange>());
- GlobalSelectionSystem().addSelectionChangeCallback(FreeCaller1<const Selectable&, UpdateWorkzone_ForSelection>());
- Selection_boundsChanged = GlobalSceneGraph().addBoundsChangedCallback(FreeCaller<UpdateWorkzone_ForSelection>());
+ typedef FreeCaller1<const Selectable&, SceneSelectionChange> SceneSelectionChangeCaller;
+ GlobalSelectionSystem().addSelectionChangeCallback(SceneSelectionChangeCaller());
+ typedef FreeCaller1<const Selectable&, UpdateWorkzone_ForSelectionChanged> UpdateWorkzoneForSelectionChangedCaller;
+ GlobalSelectionSystem().addSelectionChangeCallback(UpdateWorkzoneForSelectionChangedCaller());
+ typedef FreeCaller<UpdateWorkzone_ForSelection> UpdateWorkzoneForSelectionCaller;
+ Selection_boundsChanged = GlobalSceneGraph().addBoundsChangedCallback(UpdateWorkzoneForSelectionCaller());
}
void Selection_destroy()
{
SetManipulatorMode(eTranslate);
pivotChanged();
- addSelectionChangeCallback(pivotChangedSelectionCaller(*this));
+ addSelectionChangeCallback(PivotChangedSelectionCaller(*this));
AddGridChangeCallback(PivotChangedCaller(*this));
}
void pivotChanged() const
{
pivotChanged();
}
- typedef MemberCaller1<RadiantSelectionSystem, const Selectable&, &RadiantSelectionSystem::pivotChangedSelection> pivotChangedSelectionCaller;
+ typedef MemberCaller1<RadiantSelectionSystem, const Selectable&, &RadiantSelectionSystem::pivotChangedSelection> PivotChangedSelectionCaller;
void SetMode(EMode mode)
{
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();
}