| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 # TODO (qinmin): Need to refactor this file as base should not know about | 6 # TODO (qinmin): Need to refactor this file as base should not know about |
| 7 # higher level concepts. Currently this file has knowledge about higher level | 7 # higher level concepts. Currently this file has knowledge about higher level |
| 8 # java classes. | 8 # java classes. |
| 9 | 9 |
| 10 """Extracts native methods from a Java file and generates the JNI bindings. | 10 """Extracts native methods from a Java file and generates the JNI bindings. |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 130 'Ljava/util/ArrayList', | 130 'Ljava/util/ArrayList', |
| 131 'Ljava/util/HashMap', | 131 'Ljava/util/HashMap', |
| 132 'Ljava/util/List', | 132 'Ljava/util/List', |
| 133 'Landroid/content/Context', | 133 'Landroid/content/Context', |
| 134 'Landroid/graphics/Bitmap', | 134 'Landroid/graphics/Bitmap', |
| 135 'Landroid/graphics/Canvas', | 135 'Landroid/graphics/Canvas', |
| 136 'Landroid/graphics/Rect', | 136 'Landroid/graphics/Rect', |
| 137 'Landroid/graphics/RectF', | 137 'Landroid/graphics/RectF', |
| 138 'Landroid/graphics/Matrix', | 138 'Landroid/graphics/Matrix', |
| 139 'Landroid/graphics/Point', | 139 'Landroid/graphics/Point', |
| 140 'Landroid/media/MediaPlayer', |
| 140 'Landroid/os/Message', | 141 'Landroid/os/Message', |
| 141 'Landroid/view/KeyEvent', | 142 'Landroid/view/KeyEvent', |
| 142 'Landroid/view/Surface', | 143 'Landroid/view/Surface', |
| 143 'Landroid/view/View', | 144 'Landroid/view/View', |
| 144 'Landroid/webkit/ValueCallback', | 145 'Landroid/webkit/ValueCallback', |
| 145 'Ljava/io/InputStream', | 146 'Ljava/io/InputStream', |
| 146 'Ljava/nio/ByteBuffer', | 147 'Ljava/nio/ByteBuffer', |
| 147 'Ljava/util/Vector', | 148 'Ljava/util/Vector', |
| 148 ] | 149 ] |
| 149 app_param_list = [ | 150 app_param_list = [ |
| (...skipping 837 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 987 input_file = options.input_file | 988 input_file = options.input_file |
| 988 output_file = None | 989 output_file = None |
| 989 if options.output_dir: | 990 if options.output_dir: |
| 990 root_name = os.path.splitext(os.path.basename(input_file))[0] | 991 root_name = os.path.splitext(os.path.basename(input_file))[0] |
| 991 output_file = os.path.join(options.output_dir, root_name) + '_jni.h' | 992 output_file = os.path.join(options.output_dir, root_name) + '_jni.h' |
| 992 GenerateJNIHeader(input_file, output_file, options.namespace) | 993 GenerateJNIHeader(input_file, output_file, options.namespace) |
| 993 | 994 |
| 994 | 995 |
| 995 if __name__ == '__main__': | 996 if __name__ == '__main__': |
| 996 sys.exit(main(sys.argv)) | 997 sys.exit(main(sys.argv)) |
| OLD | NEW |