Fix the project code style, as it is not consistent. (#236)
Fixes #202 This PR fixes code style for the project files. The Problem Different files in the project use different code style. That is not consistent and leads to harder maintenance of the project. Description of the changes: Have investigated and determined the most used code style across the given codebase Have configured IDE and applied code style to all project files. Have crafted clang-formatter config. see https://clang.llvm.org/docs/ClangFormat.html https://clang.llvm.org/docs/ClangFormatStyleOptions.html Some cases were fixed manually How changes were validated: manual/ad-hoc testing, automated testing All tests pass as before because these are only code style changes. Additional Please review, and let me know if I have any mistake in the code style. In case of any mistake, I will change the configuration and re-apply it to the project.
This commit is contained in:
		
				
					committed by
					
						 Daniel Belcher
						Daniel Belcher
					
				
			
			
				
	
			
			
			
						parent
						
							c77f1de84c
						
					
				
				
					commit
					2826d37056
				
			| @@ -15,7 +15,8 @@ | ||||
|  | ||||
| namespace CalculatorApp | ||||
| { | ||||
|     public ref class DelighterUnitToStyleConverter sealed : public Windows::UI::Xaml::Data::IValueConverter | ||||
| public | ||||
|     ref class DelighterUnitToStyleConverter sealed : public Windows::UI::Xaml::Data::IValueConverter | ||||
|     { | ||||
|     public: | ||||
|         DelighterUnitToStyleConverter() | ||||
| @@ -24,18 +25,24 @@ namespace CalculatorApp | ||||
|             m_delighters->Source = ref new Windows::Foundation::Uri(L"ms-appx:///Views/DelighterUnitStyles.xaml"); | ||||
|         } | ||||
|  | ||||
|     internal: | ||||
|         virtual Platform::Object^ Convert(Platform::Object^ value, Windows::UI::Xaml::Interop::TypeName targetType, Platform::Object^ parameter, Platform::String^ language) = Windows::UI::Xaml::Data::IValueConverter::Convert; | ||||
|         virtual Platform::Object^ ConvertBack(Platform::Object^ value, Windows::UI::Xaml::Interop::TypeName targetType, Platform::Object^ parameter, Platform::String^ language) = Windows::UI::Xaml::Data::IValueConverter::ConvertBack; | ||||
|         internal : virtual Platform::Object | ||||
|                    ^ Convert(Platform::Object ^ value, Windows::UI::Xaml::Interop::TypeName targetType, Platform::Object ^ parameter, | ||||
|                              Platform::String ^ language) = Windows::UI::Xaml::Data::IValueConverter::Convert; | ||||
|         virtual Platform::Object | ||||
|             ^ ConvertBack(Platform::Object ^ value, Windows::UI::Xaml::Interop::TypeName targetType, Platform::Object ^ parameter, | ||||
|                           Platform::String ^ language) = Windows::UI::Xaml::Data::IValueConverter::ConvertBack; | ||||
|  | ||||
|     private: | ||||
|         Windows::UI::Xaml::ResourceDictionary^ m_delighters; | ||||
|         Windows::UI::Xaml::ResourceDictionary ^ m_delighters; | ||||
|     }; | ||||
|  | ||||
|     public ref class SupplementaryResultDataTemplateSelector sealed : public Windows::UI::Xaml::Controls::DataTemplateSelector | ||||
| public | ||||
|     ref class SupplementaryResultDataTemplateSelector sealed : public Windows::UI::Xaml::Controls::DataTemplateSelector | ||||
|     { | ||||
|     public: | ||||
|         SupplementaryResultDataTemplateSelector() {} | ||||
|         SupplementaryResultDataTemplateSelector() | ||||
|         { | ||||
|         } | ||||
|  | ||||
|         property Windows::UI::Xaml::DataTemplate^ RegularTemplate | ||||
|         { | ||||
| @@ -53,22 +60,22 @@ namespace CalculatorApp | ||||
|         virtual Windows::UI::Xaml::DataTemplate^ SelectTemplateCore(Platform::Object^ item, Windows::UI::Xaml::DependencyObject^ container) override; | ||||
|  | ||||
|     private: | ||||
|         Windows::UI::Xaml::DataTemplate^ m_regularTemplate; | ||||
|         Windows::UI::Xaml::DataTemplate^ m_delighterTemplate; | ||||
|         Windows::UI::Xaml::DataTemplate ^ m_regularTemplate; | ||||
|         Windows::UI::Xaml::DataTemplate ^ m_delighterTemplate; | ||||
|     }; | ||||
|  | ||||
|     public ref class SupplementaryResultNoOverflowStackPanel sealed: public CalculatorApp::Controls::HorizontalNoOverflowStackPanel | ||||
| public | ||||
|     ref class SupplementaryResultNoOverflowStackPanel sealed : public CalculatorApp::Controls::HorizontalNoOverflowStackPanel | ||||
|     { | ||||
|     protected: | ||||
|         virtual bool ShouldPrioritizeLastItem() override; | ||||
|     }; | ||||
|  | ||||
|     [Windows::Foundation::Metadata::WebHostHidden] | ||||
|     public ref class SupplementaryResults sealed | ||||
|     [Windows::Foundation::Metadata::WebHostHidden] public ref class SupplementaryResults sealed | ||||
|     { | ||||
|     public: | ||||
|         SupplementaryResults(); | ||||
|         DEPENDENCY_PROPERTY_OWNER(SupplementaryResults); | ||||
|         DEPENDENCY_PROPERTY_WITH_DEFAULT(Windows::Foundation::Collections::IIterable<ViewModel::SupplementaryResult^>^, Results, nullptr); | ||||
|         DEPENDENCY_PROPERTY_WITH_DEFAULT(Windows::Foundation::Collections::IIterable<ViewModel::SupplementaryResult ^> ^, Results, nullptr); | ||||
|     }; | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user