-6

我想做长长的吐司,但我完全不明白。你能帮助我吗?

public void onClick(View v) {


    showing  = new StringBuilder();


    if (yes.isChecked())           {
        diana.setEnabled(true);
        jimmy.setEnabled(true);
        dina.setEnabled(true);
        jack.setEnabled(true);      } 

    if(no.isChecked()==true) {
         diana.setChecked(false);
         jimmy.setChecked(false);
         dina.setChecked(false);
         jack.setChecked(false);
          }

     if(diana.isChecked())
        {showing.append(" Diana ");}
     if(jimmy.isChecked())
        {showing.append(" Jimmy ");}
     if(dina.isChecked())
        {showing.append(" Dina ");}
     if(jack.isChecked())
        {showing.append(" jhftytuyhuggfdefrtgyh sdhcgwefguwiuh ");}

//**************************thats true??????????????*******************//    
        switch (v.getId()) {
        case R.id.show:
            NotificationManagerService.scheduleTimeoutLocked() {
            if(yes.isChecked())
            {Toast.makeText(MyClass.this, "You have selected " + str, Toast.LENGTH_LONG).show();}
            long delay = immediate ? 0 : (r.duration == Toast.LENGTH_LONG ? LONG_DELAY : SHORT_DELAY);
            private static final int LONG_DELAY = 3500; // 3.5 seconds
            private static final int SHORT_DELAY = 2000; // 2 seconds
    }
}
}
4

2 回答 2

0

这已经回答了,您需要使用状态栏通知

谷歌搜索引擎


吐司长度帖子

于 2013-05-15T18:21:44.570 回答
0
Toast.makeText(this, "YOUR TEXT HERE", Toast.LENGTH_LONG).show();
于 2013-05-15T18:42:21.630 回答