Revision e6dbe81a
Added by Leszek Koltunski 6 months ago
| src/main/java/org/distorted/config/ConfigActivity.java | ||
|---|---|---|
| 114 | 114 |
ConfigSurfaceView view = findViewById(R.id.configSurfaceView); |
| 115 | 115 |
ObjectControl control = view.getObjectControl(); |
| 116 | 116 |
control.repaintPuzzleFace(cubit,face,color); |
| 117 |
mDisplayMessageDialog = false; |
|
| 117 |
|
|
| 118 |
if( mDisplayMessageDialog ) |
|
| 119 |
{
|
|
| 120 |
mDisplayMessageDialog = false; |
|
| 121 |
SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(this); |
|
| 122 |
SharedPreferences.Editor editor = preferences.edit(); |
|
| 123 |
editor.putBoolean("configDisplayDialog", mDisplayMessageDialog );
|
|
| 124 |
editor.apply(); |
|
| 125 |
} |
|
| 118 | 126 |
} |
| 119 | 127 |
} |
| 120 | 128 |
|
| ... | ... | |
| 154 | 162 |
|
| 155 | 163 |
private void savePreferences() |
| 156 | 164 |
{
|
| 157 |
SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(this); |
|
| 158 |
SharedPreferences.Editor editor = preferences.edit(); |
|
| 159 |
|
|
| 160 | 165 |
ConfigSurfaceView view = findViewById(R.id.configSurfaceView); |
| 161 | 166 |
view.getObjectControl().savePreferences(); |
| 162 |
|
|
| 163 |
editor.putBoolean("configDisplayDialog", mDisplayMessageDialog );
|
|
| 164 |
|
|
| 165 |
editor.apply(); |
|
| 166 | 167 |
} |
| 167 | 168 |
|
| 168 | 169 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
Also available in: Unified diff
more work on Preferences