mirror of
https://github.com/minibits-cash/minibits_wallet.git
synced 2026-10-05 19:28:26 +00:00
Remove icon change functionality
This commit is contained in:
@@ -96,7 +96,7 @@ android {
|
||||
applicationId "com.minibits_wallet"
|
||||
minSdkVersion rootProject.ext.minSdkVersion
|
||||
targetSdkVersion rootProject.ext.targetSdkVersion
|
||||
versionCode 58010
|
||||
versionCode 58011
|
||||
versionName "0.1.9"
|
||||
}
|
||||
|
||||
|
||||
@@ -11,62 +11,47 @@
|
||||
android:supportsRtl="true"
|
||||
android:usesCleartextTraffic="true"
|
||||
>
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:label="@string/app_name"
|
||||
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|screenSize|smallestScreenSize|uiMode"
|
||||
android:launchMode="singleTask"
|
||||
android:windowSoftInputMode="adjustResize"
|
||||
android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
<category android:name="android.intent.category.BROWSABLE"/>
|
||||
<category android:name="android.intent.category.DEFAULT"/>
|
||||
<data android:scheme="lightning"/>
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
<category android:name="android.intent.category.BROWSABLE"/>
|
||||
<category android:name="android.intent.category.DEFAULT"/>
|
||||
<data android:scheme="lnurlw"/>
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
<category android:name="android.intent.category.BROWSABLE"/>
|
||||
<category android:name="android.intent.category.DEFAULT"/>
|
||||
<data android:scheme="lnurlp"/>
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW"/>
|
||||
<category android:name="android.intent.category.BROWSABLE"/>
|
||||
<category android:name="android.intent.category.DEFAULT"/>
|
||||
<data android:scheme="cashu"/>
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<activity-alias
|
||||
android:name=".MainActivityDefault"
|
||||
android:enabled="true"
|
||||
android:exported="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:targetActivity=".MainActivity">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
</intent-filter>
|
||||
</activity-alias>
|
||||
<activity-alias
|
||||
android:name=".MainActivityGolden"
|
||||
android:enabled="false"
|
||||
android:exported="true"
|
||||
android:icon="@mipmap/ic_launcher_golden"
|
||||
android:targetActivity=".MainActivity">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
</intent-filter>
|
||||
</activity-alias>
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:label="@string/app_name"
|
||||
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|screenSize|smallestScreenSize|uiMode"
|
||||
android:launchMode="singleTask"
|
||||
android:windowSoftInputMode="adjustResize"
|
||||
android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
</intent-filter>
|
||||
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:scheme="lightning" />
|
||||
</intent-filter>
|
||||
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:scheme="lnurlw" />
|
||||
</intent-filter>
|
||||
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:scheme="lnurlp" />
|
||||
</intent-filter>
|
||||
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:scheme="cashu" />
|
||||
</intent-filter>
|
||||
|
||||
</activity>
|
||||
</application>
|
||||
</manifest>
|
||||
+2
-3
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "minibits_wallet",
|
||||
"version": "0.1.9-beta.10",
|
||||
"version": "0.1.9-beta.11",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"android:clean": "cd android && ./gradlew clean",
|
||||
@@ -37,8 +37,7 @@
|
||||
"@react-navigation/native": "^6.1.18",
|
||||
"@react-navigation/native-stack": "^6.11.0",
|
||||
"@react-navigation/stack": "^6.4.1",
|
||||
"@sentry/react-native": "^5.32.0",
|
||||
"@synonymdev/react-native-change-icon": "^5.0.0",
|
||||
"@sentry/react-native": "^5.32.0",
|
||||
"date-fns": "^4.0.0",
|
||||
"i18n-js": "^4.4.3",
|
||||
"js-lnurl": "^0.6.0",
|
||||
|
||||
@@ -9,7 +9,6 @@ import {
|
||||
CODEPUSH_PRODUCTION_DEPLOYMENT_KEY,
|
||||
} from '@env'
|
||||
import codePush, { RemotePackage } from 'react-native-code-push'
|
||||
import { changeIcon, getIcon, resetIcon } from '@synonymdev/react-native-change-icon'
|
||||
import {ThemeCode, Themes, colors, spacing, useThemeColor} from '../theme'
|
||||
import {SettingsStackScreenProps} from '../navigation' // @demo remove-current-line
|
||||
import {ListItem, Screen, Text, Card, NwcIcon, Button, BottomModal, InfoModal, Icon} from '../components'
|
||||
@@ -234,31 +233,14 @@ export const SettingsScreen: FC<SettingsScreenProps> = observer(
|
||||
const onSelectTheme = async function(theme: ThemeCode) {
|
||||
if(currentTheme !== theme) {
|
||||
try {
|
||||
// state update causes crash because of hooks
|
||||
Database.updateUserSettings({...userSettingsStore, theme})
|
||||
setCurrentTheme(theme)
|
||||
|
||||
const currentIcon = await getIcon()
|
||||
log.trace('[onSelectTheme]', {currentIcon})
|
||||
|
||||
if(theme === ThemeCode.GOLDEN) {
|
||||
await changeIcon('Golden')
|
||||
const updatedIcon = await getIcon()
|
||||
log.trace('[onSelectTheme]', {updatedIcon})
|
||||
}
|
||||
|
||||
if(currentIcon !== 'Default') {
|
||||
await changeIcon('Default')
|
||||
const updatedIcon = await getIcon()
|
||||
log.trace('[onSelectTheme]', {updatedIcon})
|
||||
}
|
||||
|
||||
setInfo('Restart the wallet to apply new theme.')
|
||||
// state update causes crash because of hooks
|
||||
Database.updateUserSettings({...userSettingsStore, theme})
|
||||
setCurrentTheme(theme)
|
||||
setInfo('Restart the wallet to apply new theme.')
|
||||
} catch (e: any) {
|
||||
log.warn('[onSelectTheme]', e.message)
|
||||
}
|
||||
}
|
||||
|
||||
toggleThemeModal()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user