sohobloo / react-native-modal-dropdown

A react-native dropdown/picker/selector component for both Android & iOS.
MIT License
1.19k stars 477 forks source link

Freeze Android #249

Open jeanlucdu55 opened 4 years ago

jeanlucdu55 commented 4 years ago

Hi,

We have an issue when trying to open the modal on android (RN 0.62.2), the app freeze and we can't do anything.

We tried binding the onSelect function and setting the state inside the renderRow but nothing works the app still freeze.

` <ModalDropdown ref={(el) => (this._dropdown = el)} options={regionsList} onSelect={(regionId, regionName) => this.setLocalRate.bind(regionId, regionName) } renderRow={this._renderRow.bind(this)}> <TouchableOpacity onPress={() => this._dropdown.show()}> <View style={[styles.textFieldContainer, styles.picker]}>

{currentSorting.label}
            <Image
              style={{
                height: 15,
                transform: [{rotate: '90deg'}],
              }}
              resizeMode="contain"
              source={require('../../assets/UI/rightRedArrow.png')}
            />
          </View>
        </TouchableOpacity>
      </ModalDropdown>`

Thanks for your help,

Théo

donni106 commented 4 years ago

Hi @jeanlucdu55, have you tried the more up-to-date package from here: https://github.com/siemiatj/react-native-modal-dropdown?