1 | import android.app.Activity; |
2 | import android.widget.*; |
3 | import android.graphics.*; |
4 | |
5 | static void androidShowClickableImage(final S imageID, final int borderColor, final Runnable onClick) {
|
6 | thread "showimg" {
|
7 | ImageView iv = new ImageView(androidContext()); |
8 | iv.setBackgroundColor(borderColor); |
9 | iv.setImageBitmap(BitmapFactory.decodeFile(loadLibrary(imageID).getPath())); |
10 | if (onClick != null) |
11 | iv.setOnClickListener(new View.OnClickListener() {
|
12 | public void onClick(View v) {
|
13 | call(onClick); |
14 | } |
15 | }); |
16 | androidShow(iv); |
17 | } |
18 | } |
Began life as a copy of #1001281
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1005198 |
| Snippet name: | androidShowClickableImage - show clickable full-screen image |
| Eternal ID of this version: | #1005198/1 |
| Text MD5: | 88a2ecfe1d23382c31e7716cc4c737f0 |
| Author: | stefan |
| Category: | javax android |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2016-10-22 00:46:54 |
| Source code size: | 590 bytes / 18 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 692 / 670 |
| Referenced in: | [show references] |