fishwjy / MultiType-FilePicker

This is a light Android file picker library.
Apache License 2.0
1.4k stars 248 forks source link

Contant.REQUEST_CODE_PICK_IMAGE not consistent #22

Closed 4sskick closed 6 years ago

4sskick commented 6 years ago

I'm using this library to picking file image with this config Intent intent = new Intent(getActivity(), ImagePickActivity.class); intent.putExtra(IS_NEED_CAMERA, true); intent.putExtra(Constant.MAX_NUMBER, 1); startActivityForResult(intent, Constant.REQUEST_CODE_PICK_IMAGE);

I place it into register screen & add new photo. register & add new photo placed in different activity, the first time I debug & set picker file image the request code is 256. After I create the request again with same code I got different value of REQUEST_CODE_PICK_IMAGE. It produce 65635 not 256 anymore. I've been override the Contant request code with startActivityForResult(intent, 99); but I still got 65635. How can I solve this?

fishwjy commented 6 years ago

Just use the Contant.REQUEST_CODE_PICK_xxx to start the picker activity. And use the default code to receive the result. Custom request code is not supported.