Home > Mobile >  Android creates a method (parameters) inside, how to call this parameter.
Android creates a method (parameters) inside, how to call this parameter.

Time:12-04

The above code to call the create method DfuUpdateActivit, but there are int the position parameters of the above code inside how to fill in, thanks!


If (isAutomatic) {

DfuUpdateActivit ();
}
break;

}

}
});

}

Private void DfuUpdateActivit (int position) {


String address=deviceList. Get (position). GetAddress ();
Intent Intent=new Intent (getActivity (), DfuUpdateActivity. Class);
Intent. PutExtra (" address ", address).
Intent. PutExtra (" name ", deviceList. Get (position). The getName ());
//intent. PutExtra (" BluetoothDevice, "deviceList. Get (position));
startActivity(intent);

}

CodePudding user response:

DfuUpdateActivit (); This way you what is the usage scenarios in the call
Usually this is a listview item index in the overloaded methods will get this parameter

CodePudding user response:

This is generally the item click event, write a callback in the adapter
  • Related