mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 18:58:19 +00:00
Merge "Folder Title Change Listener" into 24D1-dev
This commit is contained in:
@@ -1440,6 +1440,11 @@ public class Folder extends AbstractFloatingView implements ClipPathView, DragSo
|
||||
updateTextViewFocus();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTitleChanged(CharSequence title) {
|
||||
mFolderName.setText(title);
|
||||
}
|
||||
|
||||
/**
|
||||
* Utility methods to iterate over items of the view
|
||||
*/
|
||||
|
||||
@@ -723,6 +723,7 @@ public class FolderIcon extends FrameLayout implements FolderListener, IconLabel
|
||||
requestLayout();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTitleChanged(CharSequence title) {
|
||||
mFolderName.setText(title);
|
||||
setContentDescription(getAccessiblityTitle(title));
|
||||
|
||||
@@ -213,6 +213,8 @@ public class FolderInfo extends CollectionInfo {
|
||||
void onAdd(ItemInfo item, int rank);
|
||||
void onRemove(List<ItemInfo> item);
|
||||
void onItemsChanged(boolean animate);
|
||||
void onTitleChanged(CharSequence title);
|
||||
|
||||
}
|
||||
|
||||
public boolean hasOption(int optionFlag) {
|
||||
@@ -285,6 +287,10 @@ public class FolderInfo extends CollectionInfo {
|
||||
if (modelWriter != null) {
|
||||
modelWriter.updateItemInDatabase(this);
|
||||
}
|
||||
|
||||
for (int i = 0; i < mListeners.size(); i++) {
|
||||
mListeners.get(i).onTitleChanged(title);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user