Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Unified Diff: ui/gfx/android/java_bitmap.h

Issue 484603004: New C++ -> Java enum build rule + parser/generator. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixed aosp bot and added gn rule Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/gfx/android/java_bitmap.h
diff --git a/ui/gfx/android/java_bitmap.h b/ui/gfx/android/java_bitmap.h
index 34cd26af63d5e1f7e0d7813c14007c73446e2204..d716f9fc53192fae2fc26dbd51d847827d6a27c0 100644
--- a/ui/gfx/android/java_bitmap.h
+++ b/ui/gfx/android/java_bitmap.h
@@ -14,12 +14,16 @@
namespace gfx {
// Define Bitmap Config values like BITMAP_CONFIG_ARGB_8888 in a
Sami 2014/09/03 19:04:59 nit: Update the example in the comment. Or maybe t
mkosiba (inactive) 2014/09/04 11:31:22 ok, I assumed the comment meant these are supposed
-// way that ensures they're always the same than their Java counterpart.
-
-enum BitmapConfig {
-#define DEFINE_BITMAP_CONFIG(x, y) BITMAP_##x = y,
-#include "bitmap_config_list.h"
-#undef DEFINE_BITMAP_CONFIG
+// way that ensures they're always the same as their Java counterpart.
+//
+// A Java counterpart will be generated for this enum.
+// GENERATED_JAVA_ENUM_PACKAGE: org.chromium.ui.gfx
+enum BitmapFormat {
+ BITMAP_FORMAT_NO_CONFIG,
+ BITMAP_FORMAT_ALPHA_8,
+ BITMAP_FORMAT_ARGB_4444,
+ BITMAP_FORMAT_ARGB_8888,
+ BITMAP_FORMAT_RGB_565,
};
// This class wraps a JNI AndroidBitmap object to make it easier to use. It

Powered by Google App Engine
This is Rietveld 408576698