You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: library/src/main/java/com/flipkart/chatheads/ui/ChatHeadManager.java
+5-3
Original file line number
Diff line number
Diff line change
@@ -43,10 +43,12 @@ public interface ChatHeadManager<T extends Serializable> {
43
43
voidselectChatHead(ChatHeadchatHead);
44
44
45
45
voidselectChatHead(Tkey);
46
+
46
47
/**
47
48
* Should be called when measuring of the container is done.
48
49
* Typically called from onMeasure or onLayout
49
50
* Only when {@link ChatHeadContainer#getContainerHeight()} && {@link ChatHeadContainer#getContainerWidth()} returns a positive value will arrangements start working
51
+
*
50
52
* @param height
51
53
* @param width
52
54
*/
@@ -105,11 +107,11 @@ public interface ChatHeadManager<T extends Serializable> {
* An adapter to provide views. Inspired by {@link android.support.v4.view.PagerAdapter}
13
11
*/
14
12
publicinterfaceChatHeadViewAdapter<T> {
15
13
16
14
/**
17
-
* Based on the key, this should instantiate and return a View. This View will be removed when the chathead is removed.
15
+
* Based on the key, this should instantiate and return a View. This view will be shown once {@link MaximizedArrangement} is activated.. Make sure you have added the view into the specified parent ViewGroup.
16
+
* Cache the view so that you can either detach it or remove it later.
* Should return the view used to represent a chat "head". Typically a rounded imageview.
23
-
* @param key
24
-
* @return
21
+
* This will be called when the view has to be temporarily detached. {@link #attachView(Object, ChatHead, ViewGroup)} will be called if view has to be reattached.
22
+
* You would typically remove the view from parent here, but wont reclaim resources yet.
23
+
* If a chat head is removed, this method will be called followed by {@link #removeView(Object, ChatHead, ViewGroup)}
* Should return the view used to represent a chat "head". Typically a rounded imageview. Use {@link ChatHeadManager#reloadDrawable(Serializable)} if you want to reload.
0 commit comments