From eefc79b5b28cb4a97c30ec31689c7ef9ccb9709f Mon Sep 17 00:00:00 2001 From: Maciej Suminski Date: Thu, 8 Aug 2013 19:41:20 +0200 Subject: [PATCH] Reformatting. --- common/tool/tool_dispatcher.cpp | 1 - common/tool/tool_interactive.cpp | 2 +- include/tool/delegate.h | 17 ++++++++--------- include/view/view.h | 4 ++-- pcbnew/tools/selection_tool.cpp | 8 ++++---- 5 files changed, 15 insertions(+), 17 deletions(-) diff --git a/common/tool/tool_dispatcher.cpp b/common/tool/tool_dispatcher.cpp index 91df534df7..8a73cee15e 100644 --- a/common/tool/tool_dispatcher.cpp +++ b/common/tool/tool_dispatcher.cpp @@ -229,7 +229,6 @@ void TOOL_DISPATCHER::DispatchWxEvent( wxEvent &aEvent ) m_toolMgr->ProcessEvent( *evt ); aEvent.Skip(); - } diff --git a/common/tool/tool_interactive.cpp b/common/tool/tool_interactive.cpp index 1158a2625f..3c04d81cb1 100644 --- a/common/tool/tool_interactive.cpp +++ b/common/tool/tool_interactive.cpp @@ -44,7 +44,7 @@ TOOL_INTERACTIVE::~TOOL_INTERACTIVE() } -OPT_TOOL_EVENT TOOL_INTERACTIVE::Wait ( const TOOL_EVENT_LIST & aEventList ) +OPT_TOOL_EVENT TOOL_INTERACTIVE::Wait( const TOOL_EVENT_LIST& aEventList ) { return m_toolMgr->ScheduleWait( this, aEventList ); } diff --git a/include/tool/delegate.h b/include/tool/delegate.h index 3e48b57ccc..f2841bb4ff 100644 --- a/include/tool/delegate.h +++ b/include/tool/delegate.h @@ -46,14 +46,14 @@ template template DELEGATE ( T* object, ReturnType (T::*ptr)( Arg ) ) { - m_ptr = reinterpret_cast(ptr); - m_object = reinterpret_cast (object); + m_ptr = reinterpret_cast( ptr ); + m_object = reinterpret_cast( object ); }; ReturnType operator()( Arg a ) const { - DELEGATE *casted = reinterpret_cast * >(m_object); + DELEGATE *casted = reinterpret_cast*>( m_object ); return (casted->*m_ptr)(a); } @@ -69,8 +69,7 @@ private: template class DELEGATE0 { public: - typedef ReturnType (DELEGATE0::*MemberPointer)( ); - + typedef ReturnType ( DELEGATE0::*MemberPointer )(); typedef ReturnType _ReturnType; DELEGATE0 () @@ -80,15 +79,15 @@ template template DELEGATE0 ( T* object, ReturnType (T::*ptr)( ) ) { - m_ptr = reinterpret_cast(ptr); - m_object = reinterpret_cast (object); + m_ptr = reinterpret_cast( ptr ); + m_object = reinterpret_cast( object ); }; ReturnType operator()( ) const { - DELEGATE0 *casted = reinterpret_cast * >(m_object); - return (casted->*m_ptr)(); + DELEGATE0* casted = reinterpret_cast*>( m_object ); + return ( casted->*m_ptr )(); } private: diff --git a/include/view/view.h b/include/view/view.h index daed4dc870..060de91667 100644 --- a/include/view/view.h +++ b/include/view/view.h @@ -102,7 +102,7 @@ public: * @param aRequiredId is the id of the required layer. * @param aRequired tells if the required layer should be added or removed from the list. */ - void SetRequired( int aLayerId, int aRequiredId, bool aRequired = true ); + void SetRequired( int aLayerId, int aRequiredId, bool aRequired = true ); /** * Function CopySettings() @@ -378,7 +378,7 @@ public: */ bool IsDirty() const; - static const int VIEW_MAX_LAYERS = 128; ///* maximum number of layers that may be shown + static const int VIEW_MAX_LAYERS = 128; ///* maximum number of layers that may be shown private: struct VIEW_LAYER diff --git a/pcbnew/tools/selection_tool.cpp b/pcbnew/tools/selection_tool.cpp index 4605c39185..839486f9c9 100644 --- a/pcbnew/tools/selection_tool.cpp +++ b/pcbnew/tools/selection_tool.cpp @@ -119,8 +119,8 @@ void SELECTION_TOOL::selectSingle( const VECTOR2I& aWhere, bool aAdditive ) GENERAL_COLLECTORS_GUIDE guide = getEditFrame()->GetCollectorsGuide(); GENERAL_COLLECTOR collector; - collector.Collect( pcb, GENERAL_COLLECTOR::AllBoardItems, wxPoint( aWhere.x, aWhere.y ), - guide ); + collector.Collect( pcb, GENERAL_COLLECTOR::AllBoardItems, + wxPoint( aWhere.x, aWhere.y ), guide ); switch( collector.GetCount() ) { @@ -186,7 +186,7 @@ void SELECTION_TOOL::handleHighlight( const VECTOR2D& aP ) void SELECTION_TOOL::selectMultiple() { OPT_TOOL_EVENT evt; - VIEW *v = getView(); + VIEW* v = getView(); v->Add( m_selArea ); @@ -217,7 +217,7 @@ void SELECTION_TOOL::selectMultiple() BOARD_ITEM* SELECTION_TOOL::disambiguationMenu( GENERAL_COLLECTOR *aCollector ) { OPT_TOOL_EVENT evt; - BOARD_ITEM *current = NULL; + BOARD_ITEM* current = NULL; m_menu.reset( new CONTEXT_MENU() ); m_menu->SetTitle( _( "Clarify selection" ) );