New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refresh button #11
Refresh button #11
Conversation
…, and reload it into the UI. Saves having to kill the app and re-open to see the latest changes. Should address "Issue #8 Reload Play Music Files"
I just tried it, a toast or something to inform the user about the changes might be useful, I don't see anything confirming the reload yet. |
Also, since we are using JACK, the anonymous class might better be replaced by a lambda (or even a method reference, depending on where we would put such a method) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some slight changes, but it is fine in general.
// Finds the search item and create the search view | ||
MenuItem itemSearch = menu.findItem(R.id.action_search); | ||
MenuItem itemSearch = menu. findItem(R.id.action_search); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why that space?
@@ -44,4 +44,6 @@ | |||
<color name="button_navigation_drawer_active">#11000000</color> | |||
<color name="button_navigation_drawer_text">#88000000</color> | |||
<color name="button_navigation_drawer_text_active">#ef6c00</color> | |||
<color name="white">#ffffffff</color> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is that intended more that the rest?
@@ -146,4 +146,5 @@ | |||
<string name="file_handling_category">File Handling</string> | |||
<string name="overwrite_summary">Always overwrite the exported file, even if it already exists.</string> | |||
<string name="overwrite_title">Overwrite Existing Files</string> | |||
<string name="action_refesh">Refresh</string> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is that intended more that the rest?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, Android Studio did that (added via the UI), I wonder if it's the eternal tabs vs spaces epic battle :-)
I might fix those myself, but I have no time right now, so if you do @mgillespie go ahead. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, overall, this is much better, only the few german strings that should be replaced keep me from merging it, I'll do that myself now, and merge it afterwards, or you can do that if you want :)
MenuItem itemRefreshLibrary = menu. findItem(R.id.action_refresh); | ||
itemRefreshLibrary.setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() | ||
MenuItem itemRefreshLibrary = menu.findItem(R.id.action_refresh); | ||
itemRefreshLibrary.setOnMenuItemClickListener(item -> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
} | ||
catch (NoSuperUserException | CouldNotOpenDatabaseException e) | ||
{ | ||
Toast.makeText( this, R.string.dialog_superuser_access_denied_title, Toast.LENGTH_SHORT).show(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't this quite misleading, if the thrown exception is a CouldNotOpenDatabaseException? I would not expect that to be thrown though, I've never seen it. Still, that might be something we should change later on, even though I wouldn't wait with merging the PR because of that.
@@ -106,4 +106,6 @@ | |||
<string name="file_handling_category">Dateiverarbeitung</string> | |||
<string name="overwrite_summary">Überschreiben Sie die exportierte Datei immer, auch wenn sie bereits existiert.</string> | |||
<string name="overwrite_title">Bestehende Dateien überschreiben.</string> | |||
<string name="action_refesh">Erfrischen</string> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That sounds weird, someting like "Erneut laden" (enl. load again) would be more fitting I think.
@@ -106,4 +106,6 @@ | |||
<string name="file_handling_category">Dateiverarbeitung</string> | |||
<string name="overwrite_summary">Überschreiben Sie die exportierte Datei immer, auch wenn sie bereits existiert.</string> | |||
<string name="overwrite_title">Bestehende Dateien überschreiben.</string> | |||
<string name="action_refesh">Erfrischen</string> | |||
<string name="databasereloaded">Reloaded Musikdatenbank</string> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reloaded is not german, I would suggest "Musikdatenbank neu geladen" or shorter "Datenbank erneuert"
@@ -44,6 +44,6 @@ | |||
<color name="button_navigation_drawer_active">#11000000</color> | |||
<color name="button_navigation_drawer_text">#88000000</color> | |||
<color name="button_navigation_drawer_text_active">#ef6c00</color> | |||
<color name="white">#ffffffff</color> | |||
<color name="white">#ffffffff</color> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
@@ -146,5 +146,6 @@ | |||
<string name="file_handling_category">File Handling</string> | |||
<string name="overwrite_summary">Always overwrite the exported file, even if it already exists.</string> | |||
<string name="overwrite_title">Overwrite Existing Files</string> | |||
<string name="action_refesh">Refresh</string> | |||
<string name="action_refesh">Refresh</string> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mgillespie You can merge this now.
Added a refresh button, as mentioned here #8