1 답변
-
Toast.makeText(getActivity(), (String)data.result, Toast.LENGTH_LONG).show();
Toast.makeText(getActivity(), "this is my Toast message!!! =)", Toast.LENGTH_LONG).show();
이런식으로 하시면 됩니다.
LENGTH_LONG은 Toast가 조금 오래 보여지고 LENGTH_SHORT은 짧게 나타납니다.
```LayoutInflater myInflater=LayoutInflater.from(this); View view=myInflater.inflate(R.layout.your_custom_layout,null); Toast mytoast=new Toast(this); mytoast.setView(view); mytoast.setDuration(Toast.LENGTH_LONG); mytoast.show();
이런식으로하시면 커스텀 Toast를 출력할수있습니다.
댓글 입력