{"id":187195,"date":"2020-10-31T10:10:27","date_gmt":"2020-10-31T02:10:27","guid":{"rendered":"http:\/\/4563.org\/?p=187195"},"modified":"2020-10-31T10:10:27","modified_gmt":"2020-10-31T02:10:27","slug":"%e6%b1%82%e5%8a%a9%ef%bc%8c%e6%96%b0%e5%ad%a6-android%ef%bc%8c%e6%9c%89%e4%b8%aa%e9%97%ae%e9%a2%98%ef%bc%8c%e6%9c%9b%e8%a7%a3%e7%ad%94%ef%bc%8c%e8%b0%a2%e8%b0%a2","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=187195","title":{"rendered":"\u6c42\u52a9\uff0c\u65b0\u5b66 android\uff0c\u6709\u4e2a\u95ee\u9898\uff0c\u671b\u89e3\u7b54\uff0c\u8c22\u8c22"},"content":{"rendered":"<div>\n<div>\n<div>\n<h1>                  \u6c42\u52a9\uff0c\u65b0\u5b66 android\uff0c\u6709\u4e2a\u95ee\u9898\uff0c\u671b\u89e3\u7b54\uff0c\u8c22\u8c22               <\/h1>\n<p> <\/p>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : unixiya <\/span>  <span><i><\/i> 2<\/span> <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<\/p><\/div>\n<div isfirst=\"1\"> <\/p>\n<p>\u5982\u4f55\u5b9e\u73b0\u70b9\u51fb\u8fd4\u56de\u952e\uff0c\u9000\u51fa\u4e00\u4e2a while \u5faa\u73af\u3002<\/p>\n<pre><code>public void clickPlay(){     SoundPool mSoundPool =  new SoundPool(1, AudioManager.STREAM_SYSTEM, 5);     mSoundPool.load(this,R.raw.shuidi,1);      int count = 0;     while (!result) {         keyevent_bool = keyCode != 0;         if (keyevent_bool) {                          break;         }         try {              mSoundPool.play(1, (float) 0.01, (float) 0.01, 0, 0, 1);             Thread.sleep(1 * 1000); \/\/\u8bbe\u7f6e\u6682\u505c\u7684\u65f6\u95f4 1 \u79d2             mSoundPool.stop(1);             count++;         } catch (InterruptedException e) {             e.printStackTrace();         }       }     mSoundPool.release(); }  @Override public void onBackPressed() {     super.onBackPressed();     keyCode = KeyEvent.KEYCODE_BACK; } <\/code><\/pre>\n<\/p><\/div>\n<div> <b>\u5927\u4f6c\u6709\u8a71\u8aaa<\/b> (<span>4<\/span>)        <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<ul>\n<li data-pid=\"4059726\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : yejianmail <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u73b0\u5728 Android \u7684\u67b6\u6784\u597d\u591a\u90fd\u662f mvvm\uff0c\u53ef\u4ee5\u89c2\u5bdf livedata \u7684\u72b6\u6001\u53d8\u5316\uff0c\u6216\u8005\u4f60\u628a\u64ad\u653e\u5668\u505a\u6210\u4e00\u4e2a\u72b6\u6001\u673a\uff0c\u5728\u5faa\u73af\u91cc\u6839\u636e\u72b6\u6001\u53d8\u5316\u505a\u4e0d\u540c\u7684\u4e8b\uff0c\u70b9\u51fb\u540e\u6539\u53d8\u72b6\u6001                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4059727\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : L5411 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u770b\u4ee3\u7801\u4e0d\u662f\u5df2\u7ecf\u5b9e\u73b0\u4e86\u529f\u80fd                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4059728\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : Melodyer <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u4f60\u8fd9 Thread.sleep \u6ca1\u6709\u653e\u5230\u5b50\u7ebf\u7a0b\uff0c\u76f4\u63a5\u653e\u5728\u4e3b\u7ebf\u7a0b\u4f1a\u5361 UI \u7684\u3002                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4059729\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : unixiya <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u8c22\u8c22\u5927\u5bb6\u5566\uff0c\u627e\u5230\u65b9\u6cd5\u4e86\uff0c<br \/>Executors \u521b\u5efa\u53ef\u5b9a\u65f6\u7684\u7ebf\u7a0b newScheduledThreadPool                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li>\n","protected":false},"excerpt":{"rendered":"<p>\u6c42\u52a9\uff0c\u65b0\u5b66 android\uff0c\u6709\u4e2a\u95ee&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/187195"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=187195"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/187195\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=187195"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=187195"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=187195"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}