Example #1
0
 @Override
 public void onClick(View v) {
   Message msg = new Message();
   msg.what = clickIndex;
   msg.arg1 = position;
   Bundle b = new Bundle();
   b.putSerializable(BUNDLE_KEY_LIDATA, list.get(position));
   msg.setData(b);
   mHandle.sendMessage(msg);
 }
Example #2
0
 // Send a message from the SDLMain thread
 boolean sendCommand(int command, Object data) {
   Message msg = commandHandler.obtainMessage();
   msg.arg1 = command;
   msg.obj = data;
   return commandHandler.sendMessage(msg);
 }