C# 클래스 Microsoft.Phone.Applications.UnitConverter.MainPage

Main page code behind
상속: Microsoft.Phone.Applications.UnitConverter.View.PageCommon
파일 보기 프로젝트 열기: Expensify/WindowsPhoneTestFramework

공개 메소드들

메소드 설명
MainPage ( ) : System

Default constructor

보호된 메소드들

메소드 설명
OnNavigatedFrom ( System.Windows.Navigation.NavigationEventArgs e ) : void

Called when we are leaving the page. We clear the constructorCalled flag so that we will be able to determine if we were tomb stoned or not if we receive an activation event

OnNavigatedTo ( System.Windows.Navigation.NavigationEventArgs e ) : void

Called when we have a page to navigated event This event is raised whenever we visit the page. This can occur for the following situations 1) Application Launch. We need to perform initial app initialization 2) Application Activation where we are tomb stoned, or we are still in memory If we have been tomb stoned, we need to read objects from the application service, and then perform any initialization on the restored objects. If we received and activation event, but we were not tomb stoned, then we actually don't need to do anything except clear the main application state flag and exit. This is because all objects are still in memory. 3) We have returned from the conversions page in the application.

PageLayoutUpdated ( object sender, EventArgs e ) : void

Handles the Page layout event for the main page. This event will be raised when the page has rendered, or almost fully rendered. This event can be raised multiple times, so we check to see if we were just launched. If we were, then we perform additional work to load configuration data needed by the application. This allows the initial page render to be as fast as possible

비공개 메소드들

메소드 설명
OnClickBack ( object sender, RoutedEventArgs e ) : void

Called when User clicks on the back button on the keypad. Remove one characater

OnClickClear ( object sender, RoutedEventArgs e ) : void

Called when user presses the clear key on the keypad

OnClickNumber ( object sender, RoutedEventArgs e ) : void

Called when user clicks any digit or decimal

OnClickSign ( object sender, RoutedEventArgs e ) : void

Called when User clicks on the back button on the keypad. Remove one character

OnClickSourceTargetUnit ( object sender, RoutedEventArgs e ) : void

Button handler to switch which unit is the source or target

OnConversionsClicked ( object sender, RoutedEventArgs e ) : void

Called when Conversion button is clicked to go to the conversions page.

OnFavoritesClicked ( object sender, RoutedEventArgs e ) : void

Called when Add to favorites button is clicked.

SignalFavoritesAreLoaded ( ) : void

Signals the favorites are loaded and that we can enable the navigation buttons on the page. This is called from a thread pool function, so we need to update the UI on the UI thread

메소드 상세

MainPage() 공개 메소드

Default constructor
public MainPage ( ) : System
리턴 System

OnNavigatedFrom() 보호된 메소드

Called when we are leaving the page. We clear the constructorCalled flag so that we will be able to determine if we were tomb stoned or not if we receive an activation event
protected OnNavigatedFrom ( System.Windows.Navigation.NavigationEventArgs e ) : void
e System.Windows.Navigation.NavigationEventArgs Navigation event arguments
리턴 void

OnNavigatedTo() 보호된 메소드

Called when we have a page to navigated event This event is raised whenever we visit the page. This can occur for the following situations 1) Application Launch. We need to perform initial app initialization 2) Application Activation where we are tomb stoned, or we are still in memory If we have been tomb stoned, we need to read objects from the application service, and then perform any initialization on the restored objects. If we received and activation event, but we were not tomb stoned, then we actually don't need to do anything except clear the main application state flag and exit. This is because all objects are still in memory. 3) We have returned from the conversions page in the application.
protected OnNavigatedTo ( System.Windows.Navigation.NavigationEventArgs e ) : void
e System.Windows.Navigation.NavigationEventArgs The Navigation event args
리턴 void

PageLayoutUpdated() 보호된 메소드

Handles the Page layout event for the main page. This event will be raised when the page has rendered, or almost fully rendered. This event can be raised multiple times, so we check to see if we were just launched. If we were, then we perform additional work to load configuration data needed by the application. This allows the initial page render to be as fast as possible
protected PageLayoutUpdated ( object sender, EventArgs e ) : void
sender object The source of the event.
e System.EventArgs Event data.
리턴 void