misc...
* fix: update projections on prev/nextleakspot
* use active projection for prev/nextleakspot tracking
* fix of: no redo available after ( nothing selected + M1 click ) in 2D
* fix: nudge left, right, up, down commands work in scale, rotate, clipper manipulator modes
* deprecated 'Disable system menu on popup windows' preference, was doing nothing
* preference: Nudge selected after duplication (def = no)
* preference: Left mouse click tunnel selector (def = yes)
return Vector3( 0, 0, 0 );
}
+bool g_bNudgeAfterClone = false;
+
+void Nudge_constructPreferences( PreferencesPage& page ){
+ page.appendCheckBox( "", "Nudge selected after duplication", g_bNudgeAfterClone );
+}
+
void NudgeSelection( ENudgeDirection direction, float fAmount, VIEWTYPE viewtype ){
AxisBase axes( AxisBase_forViewType( viewtype ) );
Vector3 view_direction( vector3_negated( axes.z ) );
Scene_Clone_Selected( GlobalSceneGraph(), false );
- //NudgeSelection(eNudgeRight, GetGridSize(), GlobalXYWnd_getCurrentViewType());
- //NudgeSelection(eNudgeDown, GetGridSize(), GlobalXYWnd_getCurrentViewType());
+ if( g_bNudgeAfterClone ){
+ NudgeSelection(eNudgeRight, GetGridSize(), GlobalXYWnd_getCurrentViewType());
+ NudgeSelection(eNudgeDown, GetGridSize(), GlobalXYWnd_getCurrentViewType());
+ }
}
}
Scene_Clone_Selected( GlobalSceneGraph(), true );
- //NudgeSelection(eNudgeRight, GetGridSize(), GlobalXYWnd_getCurrentViewType());
- //NudgeSelection(eNudgeDown, GetGridSize(), GlobalXYWnd_getCurrentViewType());
+ if( g_bNudgeAfterClone ){
+ NudgeSelection(eNudgeRight, GetGridSize(), GlobalXYWnd_getCurrentViewType());
+ NudgeSelection(eNudgeDown, GetGridSize(), GlobalXYWnd_getCurrentViewType());
+ }
}
}
// menu_separator( menu );
create_menu_item_with_mnemonic( menu, "Pro_ject settings...", "ProjectSettings" );
//menu_separator( menu );
- create_menu_item_with_mnemonic( menu, "_Pointfile...", "TogglePointfile" );
+ create_menu_item_with_mnemonic( menu, "_Pointfile", "TogglePointfile" );
menu_separator( menu );
MRU_constructMenu( menu );
menu_separator( menu );
GlobalPreferenceSystem().registerPreference( "XZWnd", WindowPositionTrackerImportStringCaller( g_posXZWnd ), WindowPositionTrackerExportStringCaller( g_posXZWnd ) );
GlobalPreferenceSystem().registerPreference( "EnginePath", CopiedStringImportStringCaller( g_strEnginePath ), CopiedStringExportStringCaller( g_strEnginePath ) );
+
+ GlobalPreferenceSystem().registerPreference( "NudgeAfterClone", BoolImportStringCaller( g_bNudgeAfterClone ), BoolExportStringCaller( g_bNudgeAfterClone ) );
if ( g_strEnginePath.empty() )
{
g_strEnginePath_was_empty_1st_start = true;
Layout_registerPreferencesPage();
Paths_registerPreferencesPage();
+ PreferencesDialog_addSettingsPreferences( FreeCaller1<PreferencesPage&, Nudge_constructPreferences>() );
g_brushCount.setCountChangedCallback( FreeCaller<QE_brushCountChanged>() );
g_entityCount.setCountChangedCallback( FreeCaller<QE_entityCountChanged>() );
multimon_globals_t g_multimon_globals;
-LatchedBool g_Multimon_enableSysMenuPopups( false, "Floating windows sysmenu icons" );
+//LatchedBool g_Multimon_enableSysMenuPopups( false, "Floating windows sysmenu icons" );
void MultiMonitor_constructPreferences( PreferencesPage& page ){
GtkWidget* primary_monitor = page.appendCheckBox( "Multi Monitor", "Start on Primary Monitor", g_multimon_globals.m_bStartOnPrimMon );
- GtkWidget* popup = page.appendCheckBox(
- "", "Disable system menu on popup windows",
- LatchedBoolImportCaller( g_Multimon_enableSysMenuPopups ),
- BoolExportCaller( g_Multimon_enableSysMenuPopups.m_latched )
- );
- Widget_connectToggleDependency( popup, primary_monitor );
+// GtkWidget* popup = page.appendCheckBox(
+// "", "Disable system menu on popup windows",
+// LatchedBoolImportCaller( g_Multimon_enableSysMenuPopups ),
+// BoolExportCaller( g_Multimon_enableSysMenuPopups.m_latched )
+// );
+// Widget_connectToggleDependency( popup, primary_monitor );
}
#include "preferencesystem.h"
}
GlobalPreferenceSystem().registerPreference( "StartOnPrimMon", BoolImportStringCaller( g_multimon_globals.m_bStartOnPrimMon ), BoolExportStringCaller( g_multimon_globals.m_bStartOnPrimMon ) );
- GlobalPreferenceSystem().registerPreference( "NoSysMenuPopups", BoolImportStringCaller( g_Multimon_enableSysMenuPopups.m_latched ), BoolExportStringCaller( g_Multimon_enableSysMenuPopups.m_latched ) );
+// GlobalPreferenceSystem().registerPreference( "NoSysMenuPopups", BoolImportStringCaller( g_Multimon_enableSysMenuPopups.m_latched ), BoolExportStringCaller( g_Multimon_enableSysMenuPopups.m_latched ) );
- g_Multimon_enableSysMenuPopups.useLatched();
+// g_Multimon_enableSysMenuPopups.useLatched();
PreferencesDialog_addInterfacePreferences( FreeCaller1<PreferencesPage&, MultiMonitor_constructPreferences>() );
}
CamWnd& camwnd = *g_pParentWnd->GetCamWnd();
Camera_setOrigin( camwnd, *i );
- g_pParentWnd->GetXYWnd()->SetOrigin( *i );
+ g_pParentWnd->ActiveXY()->SetOrigin( *i );
+ g_pParentWnd->ActiveXY()->queueDraw();
{
Vector3 dir( vector3_normalised( vector3_subtracted( *( ++i ), Camera_getOrigin( camwnd ) ) ) );
Vector3 angles( Camera_getAngles( camwnd ) );
CamWnd& camwnd = *g_pParentWnd->GetCamWnd();
Camera_setOrigin( camwnd, *i );
- g_pParentWnd->GetXYWnd()->SetOrigin( *i );
+ g_pParentWnd->ActiveXY()->SetOrigin( *i );
+ g_pParentWnd->ActiveXY()->queueDraw();
{
Vector3 dir( vector3_normalised( vector3_subtracted( *( ++i ), Camera_getOrigin( camwnd ) ) ) );
Vector3 angles( Camera_getAngles( camwnd ) );
/// \todo Support view-dependent nudge.
void NudgeManipulator( const Vector3& nudge, const Vector3& view ){
- if ( ManipulatorMode() == eTranslate || ManipulatorMode() == eDrag ) {
+// if ( ManipulatorMode() == eTranslate || ManipulatorMode() == eDrag ) {
translateSelected( nudge );
- }
+// }
}
void endMove();
#include "preferencesystem.h"
#include "preferences.h"
+bool g_bLeftMouseClickSelector = true;
+
void SelectionSystem_constructPreferences( PreferencesPage& page ){
page.appendCheckBox( "", "Prefer point entities in 2D", getSelectionSystem().m_bPreferPointEntsIn2D );
+ page.appendCheckBox( "", "Left mouse click tunnel selector", g_bLeftMouseClickSelector );
}
void SelectionSystem_constructPage( PreferenceGroup& group ){
PreferencesPage page( group.createPage( "Selection", "Selection System Settings" ) );
GlobalShaderCache().attachRenderable( getSelectionSystem() );
GlobalPreferenceSystem().registerPreference( "PreferPointEntsIn2D", BoolImportStringCaller( getSelectionSystem().m_bPreferPointEntsIn2D ), BoolExportStringCaller( getSelectionSystem().m_bPreferPointEntsIn2D ) );
+ GlobalPreferenceSystem().registerPreference( "LeftMouseClickSelector", BoolImportStringCaller( g_bLeftMouseClickSelector ), BoolExportStringCaller( g_bLeftMouseClickSelector ) );
SelectionSystem_registerPreferencesPage();
}
modifier = RadiantSelectionSystem::eCycle;
}
getSelectionSystem().SelectPoint( *m_view, &position[0], &m_epsilon[0], modifier, false );*/
- getSelectionSystem().SelectPoint( *m_view, &position[0], &m_epsilon[0], m_mouseMoved ? RadiantSelectionSystem::eReplace : RadiantSelectionSystem::eCycle, false );
+ if( g_bLeftMouseClickSelector ){
+ getSelectionSystem().SelectPoint( *m_view, &position[0], &m_epsilon[0], m_mouseMoved ? RadiantSelectionSystem::eReplace : RadiantSelectionSystem::eCycle, false );
+ }
m_start = m_current = device_constrained( position );
}
}
else
{
- if ( button == c_button_select ) {
- m_selector.m_mouse2 = false;
- }
- else{
- m_selector.m_mouse2 = true;
- }
+ m_selector.m_mouse2 = ( button == c_button_select ) ? false : true;
m_selector.mouseDown( devicePosition );
g_mouseMovedCallback.insert( MouseEventCallback( Selector_::MouseMovedCaller( m_selector ) ) );
g_mouseUpCallback.insert( MouseEventCallback( Selector_::MouseUpCaller( m_selector ) ) );
m_nNewBrushPressy = y;
m_bNewBrushDrag = true;
- GlobalUndoSystem().start();
}
void XYWnd::NewBrushDrag_End( int x, int y ){
}
if ( m_NewBrushDrag == 0 ) {
+ GlobalUndoSystem().start();
NodeSmartReference node( GlobalBrushCreator().createBrush() );
Node_getTraversable( Map_FindOrInsertWorldspawn( g_map ) )->insert( node );