Merge "docs: migration guide link update" into mnc-preview-docs
diff --git a/core/java/android/nfc/cardemulation/CardEmulation.java b/core/java/android/nfc/cardemulation/CardEmulation.java
index 64c2bc2..23d05bd 100644
--- a/core/java/android/nfc/cardemulation/CardEmulation.java
+++ b/core/java/android/nfc/cardemulation/CardEmulation.java
@@ -40,7 +40,7 @@
  * NFC card emulation services.
  *
  * For a general introduction into NFC card emulation,
- * please read the <a href="{@docRoot}guide/topics/nfc/ce.html">
+ * please read the <a href="{@docRoot}guide/topics/connectivity/nfc/hce.html">
  * NFC card emulation developer guide</a>.</p>
  *
  * <p class="note">Use of this class requires the
diff --git a/docs/html/tools/workflow/index.jd b/docs/html/tools/workflow/index.jd
index a24a2b0..b32fa26 100644
--- a/docs/html/tools/workflow/index.jd
+++ b/docs/html/tools/workflow/index.jd
@@ -41,16 +41,16 @@
     <a href="{@docRoot}tools/projects/index.html">Create an Android project</a>.</p>
   </li>
   <li><strong>Building, Debugging and Testing</strong>
-    <p>During this phase you build your project into a debuggable <code>.apk</code> package(s) 
-    that you can install and run on the emulator or an Android-powered device. Android Studio uses 
-    a build system based on <a href="http://www.gradle.org/" target="_android">Gradle</a> 
-    that provides flexibility, customized build variants, dependency resolution, and much more. 
-    If you're using another IDE, you can build your project using Gradle and install it on a device 
+    <p>During this phase you build your project into a debuggable <code>.apk</code> package(s)
+    that you can install and run on the emulator or an Android-powered device. Android Studio uses
+    a build system based on <a href="http://www.gradle.org/" target="_android">Gradle</a>
+    that provides flexibility, customized build variants, dependency resolution, and much more.
+    If you're using another IDE, you can build your project using Gradle and install it on a device
     using <a href="{@docRoot}tools/help/adb.html">adb</a>. For more information, see
     <a href="{@docRoot}tools/building/index.html">Build and run your application</a>.</p>
     <p>Next, with Android Studio you debug your application using the
-    <a href="{@docRoot}tools/help/monitor.html">Android Debug Monitor</a> and device log messages
-    (<a href="{@docRoot}tools/help/logcat.html">logact</a>) along with the IntelliJ IDEA intelligent
+    <a href="{@docRoot}tools/help/monitor.html">Android Device Monitor</a> and device log messages
+    (<a href="{@docRoot}tools/help/logcat.html">logcat</a>) along with the IntelliJ IDEA intelligent
     coding features. You can also use a JDWP-compliant debugger along with the debugging and logging
     tools that are provided with the Android SDK. For more information see
     <a href="{@docRoot}tools/debugging/index.html">Debug your application with the SDK debugging and logging tools</a>.</p>
diff --git a/docs/html/training/wearables/watch-faces/drawing.jd b/docs/html/training/wearables/watch-faces/drawing.jd
index 8b6de76..30a7a6f 100644
--- a/docs/html/training/wearables/watch-faces/drawing.jd
+++ b/docs/html/training/wearables/watch-faces/drawing.jd
@@ -457,9 +457,23 @@
 round devices. You can use this canvas to draw your watch face directly as follows:</p>
 
 <ol>
-<li>If this is the first invocation of the
-<a href="{@docRoot}reference/android/support/wearable/watchface/CanvasWatchFaceService.Engine.html#onDraw(android.graphics.Canvas, android.graphics.Rect)"><code>onDraw()</code></a>
-method, scale your background to fit.</li>
+<li>Override the
+<a href="{@docRoot}reference/android/support/wearable/watchface/CanvasWatchFaceService.Engine.html#onSurfaceChanged(android.view.SurfaceHolder, int, int, int)"><code>onSurfaceChanged()</code></a>
+method to scale your background to fit the device any time the view changes.
+<pre>
+&#64;Override
+public void onSurfaceChanged(
+        SurfaceHolder holder, int format, int width, int height) {
+    if (mBackgroundScaledBitmap == null
+            || mBackgroundScaledBitmap.getWidth() != width
+            || mBackgroundScaledBitmap.getHeight() != height) {
+        mBackgroundScaledBitmap = Bitmap.createScaledBitmap(mBackgroundBitmap,
+                width, height, true /* filter */);
+    }
+    super.onSurfaceChanged(holder, format, width, height);
+}
+</pre>
+</li>
 <li>Check whether the device is in ambient mode or interactive mode.</li>
 <li>Perform any required graphic computations.</li>
 <li>Draw your background bitmap on the canvas.</li>
@@ -482,13 +496,6 @@
     int width = bounds.width();
     int height = bounds.height();
 
-    // Draw the background, scaled to fit.
-    if (mBackgroundScaledBitmap == null
-        || mBackgroundScaledBitmap.getWidth() != width
-        || mBackgroundScaledBitmap.getHeight() != height) {
-        mBackgroundScaledBitmap = Bitmap.createScaledBitmap(mBackgroundBitmap,
-                                      width, height, true);
-    }
     canvas.drawBitmap(mBackgroundScaledBitmap, 0, 0, null);
 
     // Find the center. Ignore the window insets so that, on round watches