cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From purplecabb...@apache.org
Subject [5/5] git commit: disable idle detection when debugging for wp8 as well
Date Wed, 13 Nov 2013 01:56:46 GMT
disable idle detection when debugging for wp8 as well


Project: http://git-wip-us.apache.org/repos/asf/cordova-wp8/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-wp8/commit/22fb2247
Tree: http://git-wip-us.apache.org/repos/asf/cordova-wp8/tree/22fb2247
Diff: http://git-wip-us.apache.org/repos/asf/cordova-wp8/diff/22fb2247

Branch: refs/heads/master
Commit: 22fb2247e15ba147cdb92a08c4904ee9e40c7c8a
Parents: a9cf744
Author: purplecabbage <purplecabbage@gmail.com>
Authored: Tue Nov 12 17:56:21 2013 -0800
Committer: purplecabbage <purplecabbage@gmail.com>
Committed: Tue Nov 12 17:56:21 2013 -0800

----------------------------------------------------------------------
 wp7/template/App.xaml.cs |  9 +++++----
 wp8/template/App.xaml.cs | 11 ++++++++---
 2 files changed, 13 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-wp8/blob/22fb2247/wp7/template/App.xaml.cs
----------------------------------------------------------------------
diff --git a/wp7/template/App.xaml.cs b/wp7/template/App.xaml.cs
index 493b916..e0ca261 100644
--- a/wp7/template/App.xaml.cs
+++ b/wp7/template/App.xaml.cs
@@ -14,7 +14,7 @@
  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  KIND, either express or implied.  See the License for the
  specific language governing permissions and limitations
- under the License. 
+ under the License.
 */
 
 using System;
@@ -47,7 +47,7 @@ namespace $safeprojectname$
         /// </summary>
         public App()
         {
-            // Global handler for uncaught exceptions. 
+            // Global handler for uncaught exceptions.
             UnhandledException += Application_UnhandledException;
 
             // Show graphics profiling information while debugging.
@@ -59,7 +59,7 @@ namespace $safeprojectname$
                 // Show the areas of the app that are being redrawn in each frame.
                 //Application.Current.Host.Settings.EnableRedrawRegions = true;
 
-                // Enable non-production analysis visualization mode, 
+                // Enable non-production analysis visualization mode,
                 // which shows areas of a page that are being GPU accelerated with a colored
overlay.
                 //Application.Current.Host.Settings.EnableCacheVisualization = true;
             }
@@ -75,7 +75,8 @@ namespace $safeprojectname$
         // This code will not execute when the application is reactivated
         private void Application_Launching(object sender, LaunchingEventArgs e)
         {
-            if (System.Diagnostics.Debugger.IsAttached) {
+            if (System.Diagnostics.Debugger.IsAttached)
+            {
                 // Avoid screen locks while debugging.
                 PhoneApplicationService.Current.UserIdleDetectionMode = IdleDetectionMode.Disabled;
             }

http://git-wip-us.apache.org/repos/asf/cordova-wp8/blob/22fb2247/wp8/template/App.xaml.cs
----------------------------------------------------------------------
diff --git a/wp8/template/App.xaml.cs b/wp8/template/App.xaml.cs
index 2b7306d..e0ca261 100644
--- a/wp8/template/App.xaml.cs
+++ b/wp8/template/App.xaml.cs
@@ -14,7 +14,7 @@
  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  KIND, either express or implied.  See the License for the
  specific language governing permissions and limitations
- under the License. 
+ under the License.
 */
 
 using System;
@@ -47,7 +47,7 @@ namespace $safeprojectname$
         /// </summary>
         public App()
         {
-            // Global handler for uncaught exceptions. 
+            // Global handler for uncaught exceptions.
             UnhandledException += Application_UnhandledException;
 
             // Show graphics profiling information while debugging.
@@ -59,7 +59,7 @@ namespace $safeprojectname$
                 // Show the areas of the app that are being redrawn in each frame.
                 //Application.Current.Host.Settings.EnableRedrawRegions = true;
 
-                // Enable non-production analysis visualization mode, 
+                // Enable non-production analysis visualization mode,
                 // which shows areas of a page that are being GPU accelerated with a colored
overlay.
                 //Application.Current.Host.Settings.EnableCacheVisualization = true;
             }
@@ -75,6 +75,11 @@ namespace $safeprojectname$
         // This code will not execute when the application is reactivated
         private void Application_Launching(object sender, LaunchingEventArgs e)
         {
+            if (System.Diagnostics.Debugger.IsAttached)
+            {
+                // Avoid screen locks while debugging.
+                PhoneApplicationService.Current.UserIdleDetectionMode = IdleDetectionMode.Disabled;
+            }
         }
 
         // Code to execute when the application is activated (brought to foreground)


Mime
View raw message