diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/browser/BrowserActivity.java | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/com/android/browser/BrowserActivity.java b/src/com/android/browser/BrowserActivity.java index 43e6758..8795594 100644 --- a/src/com/android/browser/BrowserActivity.java +++ b/src/com/android/browser/BrowserActivity.java @@ -515,12 +515,13 @@ public class BrowserActivity extends Activity current.getWebView().dumpRenderTree(true); } else if ("about:debug.display".equals(urlData.mUrl)) { current.getWebView().dumpDisplayTree(); - } else if ("about:debug.drag0".equals(urlData.mUrl)) { - current.getWebView().setDragTracker(null); - } else if ("about:debug.drag1".equals(urlData.mUrl)) { - current.getWebView().setDragTracker(new MeshTracker(1)); - } else if ("about:debug.drag2".equals(urlData.mUrl)) { - current.getWebView().setDragTracker(new MeshTracker(2)); + } else if (urlData.mUrl.startsWith("about:debug.drag")) { + int index = urlData.mUrl.codePointAt(16) - '0'; + if (index <= 0 || index > 9) { + current.getWebView().setDragTracker(null); + } else { + current.getWebView().setDragTracker(new MeshTracker(index)); + } } else { mSettings.toggleDebugSettings(); } |