Chromium Code Reviews| Index: chrome/android/java/src/org/chromium/chrome/browser/compositor/resources/ResourceFactory.java |
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/compositor/resources/ResourceFactory.java b/chrome/android/java/src/org/chromium/chrome/browser/compositor/resources/ResourceFactory.java |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..06237d7e8ceb6718bece28a3e384cdc041a84788 |
| --- /dev/null |
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/compositor/resources/ResourceFactory.java |
| @@ -0,0 +1,27 @@ |
| +// Copyright 2017 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +package org.chromium.chrome.browser.compositor.resources; |
| + |
| +import android.graphics.Rect; |
| + |
| +import org.chromium.base.annotations.JNINamespace; |
| + |
| +/** |
| + * Utility class for creating native resources. |
| + */ |
| +@JNINamespace("android") |
| +public class ResourceFactory { |
| + public static long createToolbarContainerResource( |
|
mdjones
2017/03/16 21:01:47
Are we going to do something similar for the crush
David Trainor- moved to gerrit
2017/03/17 07:41:22
I think that (crushed sprite) could go in ui/ sinc
mdjones
2017/03/17 15:38:10
That makes sense, I was thinking about it as part
Khushal
2017/03/17 23:02:58
Yeah. CrushedSprite in next patch. That should be
Khushal
2017/03/17 23:49:44
I looked at CrushedSprite and they are funkier tha
|
| + Rect toolbarPosition, Rect locationBarPosition, int shadowHeight) { |
| + return nativeCreateToolbarContainerResource(toolbarPosition.left, toolbarPosition.top, |
| + toolbarPosition.right, toolbarPosition.bottom, locationBarPosition.left, |
| + locationBarPosition.top, locationBarPosition.right, locationBarPosition.bottom, |
| + shadowHeight); |
| + } |
| + |
| + private static native long nativeCreateToolbarContainerResource(int toolbarLeft, int toolbarTop, |
| + int toolbarRight, int toolbarBottom, int locationBarLeft, int locationBarTop, |
| + int locationBarRight, int locationBarBottom, int shadowHeight); |
| +} |