-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #19 from wcoder/feature/upgrade-ns2
Update solution
- Loading branch information
Showing
26 changed files
with
77 additions
and
346 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
55 changes: 9 additions & 46 deletions
55
samples/DeviceOrientation.Samples.Droid/MainApplication.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,63 +1,26 @@ | ||
using System; | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using Android.Runtime; | ||
using Plugin.CurrentActivity; | ||
|
||
namespace DeviceOrientation.Samples.Droid | ||
{ | ||
//You can specify additional application information in this attribute | ||
[Application] | ||
public class MainApplication : Application, Application.IActivityLifecycleCallbacks | ||
#if DEBUG | ||
[Application(Debuggable = true)] | ||
#else | ||
[Application(Debuggable = false)] | ||
#endif | ||
public class MainApplication : Application | ||
{ | ||
public MainApplication(IntPtr handle, JniHandleOwnership transer) | ||
:base(handle, transer) | ||
: base(handle, transer) | ||
{ | ||
} | ||
|
||
public override void OnCreate() | ||
{ | ||
base.OnCreate(); | ||
RegisterActivityLifecycleCallbacks(this); | ||
//A great place to initialize Xamarin.Insights and Dependency Services! | ||
} | ||
|
||
public override void OnTerminate() | ||
{ | ||
base.OnTerminate(); | ||
UnregisterActivityLifecycleCallbacks(this); | ||
} | ||
|
||
public void OnActivityCreated(Activity activity, Bundle savedInstanceState) | ||
{ | ||
CrossCurrentActivity.Current.Activity = activity; | ||
} | ||
|
||
public void OnActivityDestroyed(Activity activity) | ||
{ | ||
} | ||
|
||
public void OnActivityPaused(Activity activity) | ||
{ | ||
} | ||
|
||
public void OnActivityResumed(Activity activity) | ||
{ | ||
CrossCurrentActivity.Current.Activity = activity; | ||
} | ||
|
||
public void OnActivitySaveInstanceState(Activity activity, Bundle outState) | ||
{ | ||
} | ||
|
||
public void OnActivityStarted(Activity activity) | ||
{ | ||
CrossCurrentActivity.Current.Activity = activity; | ||
} | ||
|
||
public void OnActivityStopped(Activity activity) | ||
{ | ||
CrossCurrentActivity.Current.Init(this); | ||
} | ||
} | ||
} |
4 changes: 2 additions & 2 deletions
4
samples/DeviceOrientation.Samples.Droid/Properties/AndroidManifest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"> | ||
<uses-sdk android:minSdkVersion="15" /> | ||
<uses-sdk android:minSdkVersion="15" android:targetSdkVersion="26" /> | ||
<application></application> | ||
</manifest> | ||
</manifest> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
samples/DeviceOrientation.Samples.UWP/ApplicationInsights.config
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+2.45 KB
samples/DeviceOrientation.Samples.UWP/DeviceOrientation.Samples.UWP_TemporaryKey.pfx
Binary file not shown.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.