From 31f11070e37636e9c47d74ad080c4786b14ff1b7 Mon Sep 17 00:00:00 2001 From: iNPUTmice Date: Wed, 10 Sep 2014 17:59:57 +0200 Subject: [PATCH] IT'S CHRISTMAS ALREADY! --- art/ic_action_send_now.svg | 69 ++++++++++++ res/drawable-hdpi/ic_action_send_now.png | Bin 578 -> 0 bytes res/drawable-hdpi/ic_action_send_now_away.png | Bin 0 -> 932 bytes res/drawable-hdpi/ic_action_send_now_dnd.png | Bin 0 -> 1135 bytes .../ic_action_send_now_offline.png | Bin 0 -> 767 bytes .../ic_action_send_now_online.png | Bin 0 -> 1095 bytes res/drawable-mdpi/ic_action_send_now_away.png | Bin 0 -> 650 bytes res/drawable-mdpi/ic_action_send_now_dnd.png | Bin 0 -> 784 bytes .../ic_action_send_now_offline.png | Bin 0 -> 535 bytes .../ic_action_send_now_online.png | Bin 0 -> 779 bytes res/drawable-xhdpi/ic_action_send_now.png | Bin 759 -> 0 bytes .../ic_action_send_now_away.png | Bin 0 -> 1180 bytes res/drawable-xhdpi/ic_action_send_now_dnd.png | Bin 0 -> 1438 bytes .../ic_action_send_now_offline.png | Bin 0 -> 968 bytes .../ic_action_send_now_online.png | Bin 0 -> 1395 bytes .../ic_action_send_now_away.png | Bin 0 -> 1426 bytes .../ic_action_send_now_dnd.png | Bin 0 -> 1456 bytes .../ic_action_send_now_offline.png | Bin 0 -> 1433 bytes .../ic_action_send_now_online.png | Bin 0 -> 1458 bytes res/layout/fragment_conversation.xml | 2 +- res/values/strings.xml | 2 + res/xml/preferences.xml | 5 + .../services/XmppConnectionService.java | 11 +- .../ui/ConversationActivity.java | 104 ++++++++++++------ .../ui/ConversationFragment.java | 53 ++++++++- 25 files changed, 205 insertions(+), 41 deletions(-) create mode 100644 art/ic_action_send_now.svg delete mode 100644 res/drawable-hdpi/ic_action_send_now.png create mode 100644 res/drawable-hdpi/ic_action_send_now_away.png create mode 100644 res/drawable-hdpi/ic_action_send_now_dnd.png create mode 100644 res/drawable-hdpi/ic_action_send_now_offline.png create mode 100644 res/drawable-hdpi/ic_action_send_now_online.png create mode 100644 res/drawable-mdpi/ic_action_send_now_away.png create mode 100644 res/drawable-mdpi/ic_action_send_now_dnd.png create mode 100644 res/drawable-mdpi/ic_action_send_now_offline.png create mode 100644 res/drawable-mdpi/ic_action_send_now_online.png delete mode 100644 res/drawable-xhdpi/ic_action_send_now.png create mode 100644 res/drawable-xhdpi/ic_action_send_now_away.png create mode 100644 res/drawable-xhdpi/ic_action_send_now_dnd.png create mode 100644 res/drawable-xhdpi/ic_action_send_now_offline.png create mode 100644 res/drawable-xhdpi/ic_action_send_now_online.png create mode 100644 res/drawable-xxhdpi/ic_action_send_now_away.png create mode 100644 res/drawable-xxhdpi/ic_action_send_now_dnd.png create mode 100644 res/drawable-xxhdpi/ic_action_send_now_offline.png create mode 100644 res/drawable-xxhdpi/ic_action_send_now_online.png diff --git a/art/ic_action_send_now.svg b/art/ic_action_send_now.svg new file mode 100644 index 000000000..6bde9158f --- /dev/null +++ b/art/ic_action_send_now.svg @@ -0,0 +1,69 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/res/drawable-hdpi/ic_action_send_now.png b/res/drawable-hdpi/ic_action_send_now.png deleted file mode 100644 index ff0e369ee4e77c759668f484b413bd8bbadabd7e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 578 zcmV-I0=@l-P)g;nk>&nCnxMIS@;sApV{x`WMjR6BahjI`6e{ynK+S~O1 zdN{o;)M^w(Q4~c{6h%?gdg}FhT|{#qywuAKN|L0HbdP+B_?S+oUxx<3r5i+!7+3~T z7Qg~&=vPlHgNOuu;1MZavT2TZL%fd1Awt7=7Tm#IT@xL|rl%SF?-M+Hlx!MGP^%jhLV!7FGeABV7m%;hN~}E*lpZVoh=pdqsuAFO@?xY)qk2;0r_)i~6H*BmU zKeL={dR|9?KBQIlx=rIY7#ALjidU|&;&C~s+vKs*_wlac3Q?OMXaO*1ToXWU(YPjn z)S__}0RGn2v}jzb0#d8SwE$#RjcWnOts38D1qAg{v@`%Tz}&KNjS9#t8?OR@iQfn% z0CLO5MF9N2Lt@Lur4^7`H!cOxv2I)nz`c5Uuxy;7D2k#eilQj$p!Flb0N@VYT%`vC QQvd(}07*qoM6N<$g4U+^0RR91 diff --git a/res/drawable-hdpi/ic_action_send_now_away.png b/res/drawable-hdpi/ic_action_send_now_away.png new file mode 100644 index 0000000000000000000000000000000000000000..505cbe63abc1a4af6e3dd2eef57a82e53edd0e60 GIT binary patch literal 932 zcmV;V16%xwP)d&*wOysBxtt@uN~fTO`B)GeW2XVn7Ut zfq@AITG~=1#J~(HJOBd{X#xW~Z;&i~0CrG+)4l=%D%$vCurE%UM75La{G6p~V_%<> zYdbft=qe8pzOkTN3?UBSpe$09B}#Is-$F?dEpi>@LEYcB5h}wnBccV)AiQev+E9du zszOQLpp3TJW}riYfTBDGt{$`PK!yYX1)0U+Uc5cn;gAZ;x|yH`3ZvJ6b6aUfC(X$<%zck#Jp^8hWVVlkvKpd?pN zp4b>T230JCGzNT;5&p7*BHg(qF<=*^+-XQ-06qpNOM3@?gKY1swG3% zMX2yp*JEwoVg|0EJW9hY5ivuW13pTg46oC4OT;lD%>e*KxdDs=9)gD-{uD-gdV$x| zCZu&hJ66Qu6nV0EIAK%`4`nP2^Z*aV>u6;g2W5{8WfPJtAPHY3#~(a?*ToXX`gOlU zp5W<7GQtqovUbET9Dd^9;-EMj;vhIkxZ3i&9ADW-*-thDYvS@9j|?6M;XCVu?__kH zcqn;{0q^A`qnsn9 zkA{|XC~jyBIKfoUmI_^p8yW*LJve=o4WPo3R&5N|7$8iicKTQrH$(v?$>K9<{RB!$ z+)zIQ7py)L5;pNErzLKP0&14-|3-WyAya zxC8;`nV^>N8&sdg4M9MSnb>;_h`1pLh_irGwoocO)9v)N;^QJB6q#!K0XCrG2A2Y- zTmFxDz{L$N&XMJVutja~#SJbRUcf^pZg2q~pVeU#H~a&vt7n?s>SX8u0000XhP-9q8B6-gXl=5C)Wu>X)4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_PKBtx7O8E}l#P*%g1lQxaVa*z40ju^&5?rwqNE%$p;Os%=R>K+- zT#uiarHVlBz&7zuP!}3pQGvaPF`Wpms6a^nAK`)@x0olIOhkm$Z=^dJT*-iI`2QpB xbZ{l3-afquu4Me1z`Y8tWWXQbXWxP=e*qHBN|VMN5;y<=002ovPDHLkV1mksFmwO_ literal 0 HcmV?d00001 diff --git a/res/drawable-hdpi/ic_action_send_now_online.png b/res/drawable-hdpi/ic_action_send_now_online.png new file mode 100644 index 0000000000000000000000000000000000000000..48676f7bdfd6584d541b65a8d9768703f483e953 GIT binary patch literal 1095 zcmV-N1i1T&P)Bzu(8_v{Ca$>HtFh0dee$K?++Xgir^I z0Wnkz3{0RxLmL=S2WC*<4`5&@NBO4`3!uY^QOBx-mo$5hcFoVMtyR$4PS+ z-#N}_jL*+~KDzhyogL0Bl|NDC?~S{S7S17J5TV$;nWdTea4{^OwNP3ZJ`CSMtRHv( zVzO>#(RsNdEI%l}DgnOjd*z&j(994nhu;%+>Bu8SJcMS3>T=~X17=@(A@&snw zP}Qh)uhqzMuBRIS0O3;jHEC0MoG7o5o`C97rnELPt%iNDBV@JX0) zLyH=(#TEP&v^h6ypSt%2508`2X10O4|YpRg;L*rnjKAx8y#MA&rwgbxWi9#u}cBLb|*ndU%>3+*@>Oa?eB86OTkGYeE|Rv zJ`CR#)yn`KNT+}U;HY+Km>c{c1lwX7tsDwDGT_)D3zSNwG9iD9gTR3uN79*MQb`9N zO1jfL*(P#OJQrHsholNf!|dbPvH0KELE(TMw`+9l&_OT>z)|S{brepRnWUZXLxLRK z0RUTDTM}3xvMmA$q`;1V5LFVXb^Fl*w>zoo#6A6+m~kmLs{|w!_w)rQSmGHh z8yXq~(fS_=#XUU%*MGV`K0a~bwQSX1PFH*`ow%nbVBC#Q0XmdNg+awVJpn{qvYa1v zC}_w|F7yu>}-fK6<^&J2GOBG8neSYNrF zkGQ8BAk5|lHY{<^fjuzT4Q$xro&bRVdHoGQQx71}B!cMa+|y^7+a(|XfXda%m9*cW z&RX2FcLm64B>Y}5D&n5K0BGq%eM*Zvj8?x|UC&=DIRQylmMT-n-oQpw+!K@^lwUdW zf5am$?g`|Aln@{I^r5sUj8;D%ZE;V47}EgGowz3;R8c7Wa^A!}{{e3=9&B8Du*LuY N002ovPDHLkV1kGt>@5HQ literal 0 HcmV?d00001 diff --git a/res/drawable-mdpi/ic_action_send_now_away.png b/res/drawable-mdpi/ic_action_send_now_away.png new file mode 100644 index 0000000000000000000000000000000000000000..0fdca901a5d8443e450e352629fc618bab00be46 GIT binary patch literal 650 zcmV;50(Jd~P)fmYp0YQc427$HC8vpC8)npkh5;e>STMV=E-st>=T|28e&?4j$z;N6 zu<#1bear1{tm8kF0YF%@oP^PGGC996XaJL7;jxI9^&<`&aA};YmP-Qx{Fsh%r%vyi z&I|}bNvMX=M-pRKEpQHHtbH1T`(fD-oMfs%hJ9$g4f~4Y?V6U{=1h}>q7l#ji zo%q%p@y|@^yVTth%{kT?pOi1cr#ME+Yt_nu+md3F#a=l)w8x_(_P0_)IYVm+fB;x) z)NVry9SzevYM8*m-DoB~)vPgQtTuW_;~OU*#2AR-Ea0n(z^Z{4-`QQ=27rb!=@ie6 z;XEM7oG&*}`L7~ literal 0 HcmV?d00001 diff --git a/res/drawable-mdpi/ic_action_send_now_offline.png b/res/drawable-mdpi/ic_action_send_now_offline.png new file mode 100644 index 0000000000000000000000000000000000000000..7723f4aa94b7a5eec5fc5baf0ce02de7afebd030 GIT binary patch literal 535 zcmV+y0_gpTP)K}SIY zqM@NiLTrMyBwJtwc_*t#Hxy$>jx%v=XKb!CjqUOIJa=phcm#fpF=PIrYJh+jNfV%7 zHblS`@DMpxDnvjN_;8#n1tMb%l0JdPmTRT~WK<;J3Ao&GZ6S~la1Gq2oHGM@z91o> z4ZLTZ>je@51bhL9IqosTwq}?c03hiZxX5#peIQZ54RE^$AgnpIHK`y`Ko@xP0LTQ1 z0;<3__Vets=GfK@5&;3?6*%_{NQA@zEuak?Zy9;sl0?WFU{^`1C*b0vy5n{WpjXML zuLh$M8FGv?wFH)H8%|OOIKlpy;!o57>KVbV8erd!1#Is4JBr(c18nc-(Ss|1q#AHq zR`3P@=-~GoFvKpkGuQ?2we+ciU4SzW!F^-QEX$-CfTRl0Ei-rx0JMOEjB`iWrOp)` z2W08Lm*6-cP5(#OrJni-&H^YTcmjIcKX{|HEw4UYZob&(n^h{aV zD!&ln_vTtNz<(G91Zi}=vQ^peYF>HN0D51%M=~fOTgFiV--G2vOtxGYP6mg=c$4njB}9U&$NEu;bW8%pj=DD_}1I0k^&ji>S{L}r0YlqvuN z0E$FkYrr76e~!>^ue6W;oR0uYn@hG9^&XR7i5rD`04MiPioD40KY)s+Wu*S&FX0}5 zUYzIh{zu`}!Qmc22$qQK=TC#C=@$IPM&mHeIvW7EN#hmEGg71?ZxZPVe0lW0~ z-tM)B5sm<6+>{W?$ioqUA|<^J8~S^%MiY(zP$(^{I_mKC_zhonX2v_siiQ9H002ov JPDHLkV1nI8ONsyh literal 0 HcmV?d00001 diff --git a/res/drawable-xhdpi/ic_action_send_now.png b/res/drawable-xhdpi/ic_action_send_now.png deleted file mode 100644 index 373dde239e0ebd7e9935ae186473c955cfce9081..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 759 zcmeAS@N?(olHy`uVBq!ia0vp^2_VeD1|%QND7OGok|nMYCBgY=CFO}lsSJ)O`AMk? zp1FzXsX?iUDV2pMQ*9U+m}YvqIEGZ*dNaq?U)oW?;e25S3#;B6rZv0U9<5uzaMG)h zTWXex$jVRYL7(M+$gXteoT{3U+4-bPtjpw#S9i+Xj<+|=H*c?g@40%a{g!KIZ|{tJ zKX+~_&~{{yZ8X#8+>*C~onK#=+dinU`KNfd{N;X+-^TOL{})P&W>kLJw{+^IbApNb z2TFtg7qAO{V~Sh)JFHqt@c)A4Asy?NNb6Oe?%pDuxj%jLO>W5xHDWt%)@^vAo6@qW zp;7KA)BbQ!I=TP=S33$|aH=W;~bG-0<@!QQ6=<(KL_dn?qK%}zH3zhsN%3G~=q za9=y<9EUICIu3bLgOE!~CaiC~%WplH;MsLSuT;rA`5j7#LoDcRpS%bc|q*KHc>q$+1tB2yl!po$Vlydky(F0 z%6f5_&99`tH)isDh}@8seuc}Nb6M_b4sOQwwpI%(K{2Kn^Ru_ywOt}Oe!LJ;Ra(=v zLH~&T-&HDXKHa7FA36UKHEN$7`%daZLyy6k2GN^_YjlHGM;VC4pI-WQ=@h}eIzfNl z_E-8|%XnD0)8)xBr8}`Q-+kqdFV~UPF-kT+8XOR4ZQ$p~<+v}#LiLT?CMBat-dZ!O z8N$;RHnRLkI@!ZNgVC~)UweVlhZKj`O!=A%6h1Vv)NDBG@SxXN;mMo*pQG9RbK@A7 zXeg|b-nxZ#3X5GWW8nQ+E7T6;ZxZ~`AUQ$!#|9=YCiyT2&j*jsHTeDU@ONzxdElGA ze|Peuh1`wT&ov}9A1ME{o_h<+6qbE=B@fIm&EWhnU7?-DE{5$1i`|-rt^@6&0YX4y n^6o~>JHU*bS{NLzR|+RE7;d!x!1aHrF-XeO)z4*}Q$iB}O!YxH diff --git a/res/drawable-xhdpi/ic_action_send_now_away.png b/res/drawable-xhdpi/ic_action_send_now_away.png new file mode 100644 index 0000000000000000000000000000000000000000..bb999d85d4e128d988763034bd6735356693c388 GIT binary patch literal 1180 zcmV;N1Y`S&P)?qyPW_8FWQhbW?9;ba!ELWdL_~cP?peYja~^ zaAhuUa%Y?FJQ@H11Q|(0K~#90<(oTm8&w#FpKrAZHui>)Vaz35tb~CSDFRJs(u9IE zX-EMyX&mA>nSmw^X@dC!6q$)6hcKR@`82)QZYD&CszO=rBP?XRW~xOr1ytlZaQ=wbPNj&ZfRbDy;A)@8OqGbHfCus} z$N4Vju~Q);0N@|~1`cu_dj@5d4O!!%d}zHhPc%mWKuK;8@X_FB;wgvJxUD;udhG9ymRM zUh0fMM4EuBz$KqebWz8nh+Y9@IgfDNNAV-5<3U8PfZt?+=iGN$G$(Z&is%&pP?5X9 z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dQQfEHxE11sbFlu^Ql802oDvh*(dH zRQ8MLS-@fWh4ely6egd&P+IxaG)-+Sr|c_HFNN7x!jOukiSD$Ch)qB*)Pi7qe8<-+ zt@NJR)5@bZ7E_AUR$huCp%Ba#Ew!;mzkXa>v6`f2vd8s-><{h;74SGWf95Hk-+)ky zf`(87GLcBP5n{mw&zS0LV`Z(|^PzkC6T5Q>ikCqE0(Ubs5L|#U)oe&`N2mZQ31pzQ z@x$SQhrQ$b2^C<;fJ5}A_Zr;MRlwui{22mM(X9T4q5{COfz5v+uyJRceDg3sz8o#)o0j( zJA456kyLjw#kqbKz_12)_yBMxQ@TJ(x|e|>ST>$l&9D8r5>IQ%-~)hCCXhq^ZRDr~ zclZEcttuR}{6{Ug!v_FT=EC;>Q4Q|!AI+4ek?Q=PK?;^V&#O+4XmE#*lnMabdf=o4 scld^;0O5%X?(hLxUwJ>BwBU~a0PdOErcF6>-~a#s07*qoM6N<$g8wFw7ytkO literal 0 HcmV?d00001 diff --git a/res/drawable-xhdpi/ic_action_send_now_offline.png b/res/drawable-xhdpi/ic_action_send_now_offline.png new file mode 100644 index 0000000000000000000000000000000000000000..6da9ff7bd40abf3ffa2437cc91fa4ae1724dc695 GIT binary patch literal 968 zcmV;(12_DMP)?qyPW_8FWQhbW?9;ba!ELWdL_~cP?peYja~^ zaAhuUa%Y?FJQ@H114T(hK~#90<(s>1)Ib!5zmph3$VCC6NL;m{0E!eq15FwzNRx&X zK$8X}1O+r{pb794JWF^5o*-8zPmu~!%${V|J9g~dnaQmENtU9lJ#+pqGvoDSSAaLb z-z>}aX(0(9z()}|0RFU1gaFTg^`76gN`wH5z^3K3R)~-+%Mg(*V5Z=lMvG7Z8^H28 z=QdJ=3RnTwDqhnl5h~yg@TKOpjS!&%CV-#7)DUePVnpn@EiDX^WtsUw~ zM6ZCCz$*uBj+KaB0ZYIqhi#9Ah+Y8+@C)$}y z3(tL~L?j|F;34onP~RyLh{y}L0{j3b0@jdX7R%j$eV)=M06;{(0=F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 zL(KawiyVctf?FC_fT;v~em2lCsIa0cxzf_zrHwS}Gzf^{b#(t{72J|^26W{8KkML@ zIsw5#a3Uw(xh%iO=~Qq_oq&PLz?i5wllTNym7iN&y4jiFmijHgIQ8Y zZrO7Ns3Tqf_gZj^4`BP}^5>(mb_DclaElKB;rZ|bzznoBlB&!KOE2!dSWBg|jPLNa3lI8xMlkcU_AcT)!%2qEj|Dk;aJlPpgs+5@xv$Ku=3IPpFyfJ6-zI^>CfO6 zUk$1NvDv-nm;|@@h%pY}*af%vgfZ~EC&w+g<$s?D*#5u^1oQv^002ovPDHLkV1j+> BaLE7w literal 0 HcmV?d00001 diff --git a/res/drawable-xxhdpi/ic_action_send_now_away.png b/res/drawable-xxhdpi/ic_action_send_now_away.png new file mode 100644 index 0000000000000000000000000000000000000000..12ec4d33f19d18ef0bde48e635cdc671609bcee5 GIT binary patch literal 1426 zcmV;D1#S9?P)ELnGt z|G(SkR?_Nh##?*={LSY0F$r}BfB`ni%oE^25}}J3Z}ATB`NVxmgd%3V#TsxY=dmP0 z0W%(tAv5=Zm4e?%B0ORR+yt&w{B9EA0W07-aKrIAPZ1FZ9_#82R=^eDcFpG|5e;Ak zECIg(=jPZ(60rax03b8p0&gs^ts(Gd5>byy0UrP#H?YkiNrW?#0Lv5II@*Qp9Ni0Gas-c%_9}dMP4LzzyJfE7b^xNNd__u?98r1Y84d zwo=V$dLbfDzzT4`m1^?ow1`;&0GYW1tf^O1PA5ea3HS_nSG^iHj*ydeCqxtpcnkPS zy_$M-LPU{(7lFI#)y&5c(wZK%UC2D-3joN>FThKx)htGoBFY4O3B0XZO*2F#qD;W_ zg00v%0{&uiyxVpmWt0iH1pKU8jUSGY5fP+_VgUe|xd*JORpXZ+MN|p+8hBH!8XbZX zQ6=C#;8V3~bO}O4m4JB`Y{f>aBB}%|0lxz0mFj7eV`SE}qq);^0no&Pt=Lc%;UeID z;1i8v0^fDq;VR%PvT#>(!B%XHkk(X7gqr|>%zT3^++D6+TED0z z!d-wxWVhfJ)$lEXIrXr zQAWtg`r+iAVF;*$ObA>=trF&>;gpE@1h|qJgS57)_IHtX-t8R$4?;Xbn!+F>z}`&3 ztu6im{*7yvB1iQy`R!)@btk$+Y48?z0h##`SSQTB8WK*yTigU>=6O>1Rn!XJ z;yMC0NZ}W;jhtLh=6SNK0AH6ch?#|gwh; zaHh$fMuwN*EiMB3+J3wSZ%G1XQ3>8sEO8lw-gJI4?i~4D)CQH!CT5kz#83HgcW4)mNEgcx1U{P zR&&&LA!U>ai1h^g2sz?|4&Krw0Z|2S$rq5Bmw^{_OPQM}gSQlofEbScJ>-H-Q3h{` zQ9vhxx5Ol%Q^8wi1!QIwxTIf7A$v%VKWw`YALNaIP>%ji2X6^cKre!~gd|`e>G8b? z-f~)iERwyfTthE|w@i7tW#&XdNl_~j~_O;&CW3ycvI~s1z&?E1*G8TKm;td0P6th@lTs7s!!MvaGCnw z=}N&jfE7@u{iNUg~cNbpZQ*3&y&1f<|SG9WW+$VDxtNx>^HVD{)w!7DN;AO+t7 g17HknrQqA)KP^!_fB_5oO#lD@07*qoM6N<$f`W2mhX4Qo literal 0 HcmV?d00001 diff --git a/res/drawable-xxhdpi/ic_action_send_now_dnd.png b/res/drawable-xxhdpi/ic_action_send_now_dnd.png new file mode 100644 index 0000000000000000000000000000000000000000..7719f81a9a42aeae09dcd7d226ec6c241b6d6162 GIT binary patch literal 1456 zcmV;h1yA~kP)KKRF@^wvqrdaiMsPgLj|_1vF5Q0w{nY z6i@&Kp@11kn1LoKpdegcf@i@z0&Q%^RuaXswuUDV#o6Q0WiMx?J-6NS&8Vy-30Ds zJQhS4pfj0FNTT=wu#xjSL4-!6fZM>0lHUy?G#~}s1a2ul=P5$OKx194K?=AA{8;h1 zK|~Em0c*f-z=b8Y5k#y&XEK=pkVNsC=>7{@VdEjjNp`rG6C-ZADb)3C{Bnd6R^yJE#I&zqD;UV@GEf9R6!OQA!bbn zCU;sW0BTvVMX)>w2Dv>a1Qu``WI~Zh87W} z0sxXI{tkGh&K-M9ts+zfm{_po8>fhq_5LawQ59fv!Ip2VBtliddBnn9lMA+dV~l7` zl|(2B07#Y4-A5oWp^Onk7l`-OE{c!qDCj?X>oe-#q>fz?3VMc^^0#r$&xPxeI zW$o`WcHZqB1A8tWA$8F~i~xD-lr^l-ngt1uJ1M4Nylil3uA&^EkY*hfr5$5{_n`oq%~VOarY1-#64Cz?cI@DgPK zNfdt%Y~yBMbqS^5B}xL4D1M$0ei@a5m#B__9YXkd>?2ODr^`H9Re-L`7x>Id!ApXG z>Kq_i%}T*bN(H3TNgH3>c8ywtm#B<@ZQxv;JM|1L!An#Gw6*hNuhxB zgOZm`6yg8}h*{0Z*z%~5+1WJ`d#1U^acuARnCbu7}!Ar^nG;uki6TwSz1*9K- z?3gP>J5B{JDH;KrG-DB#lfg@h1o+;54iU4O6WfIpQ6#|E6YwL%5$|;Hk|qi8DtJkz zfFz1v0J$)yUxF^IyZ~!}=kSp0000< KMNUMnLSTYAEOQ(H literal 0 HcmV?d00001 diff --git a/res/drawable-xxhdpi/ic_action_send_now_offline.png b/res/drawable-xxhdpi/ic_action_send_now_offline.png new file mode 100644 index 0000000000000000000000000000000000000000..1889581322980550b9d312e62980aed751d33286 GIT binary patch literal 1433 zcmV;K1!nq*P)lIJ-h zau3+3xK9${5G~*~aHHYANrVHmfSbTA!^b>Ei8yjt*I>{Bt^q%^d~6b70WDw+_zk$Q z#5R(M6_7m7)ej7y-Yd zUY@W?hB`+aTHbCiI1>OMB6oo6j`o$2L@Y2b;6317$NS7kBF>l>@G|g~r+sH65eot? zpq>w`d92|H>SR4g5i<)C=~!8B0mAo`7LK9q7+dl;8WmrzvWmVDiL)8<`-#f32HTx$Wt^2 zI)vv7yQpdCr0m94e|YgEtSrE?fS38+i9S&qyvA67hyMblLWM957lZ`3SQGFpqNf}@xkrTuo}F^ zWCUyh=WOmYGMogjF%dA-_Tw~oO%kw(m*6$E0*W_EUi48&0PLY=H77oI+B5>L5$`)t zrtG7Rc(1{0ng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xml b/res/layout/fragment_conversation.xml index b16e41132..91921fb56 100644 --- a/res/layout/fragment_conversation.xml +++ b/res/layout/fragment_conversation.xml @@ -58,7 +58,7 @@ android:layout_alignParentRight="true" android:layout_centerVertical="true" android:background="?android:selectableItemBackground" - android:src="@drawable/ic_action_send_now" /> + android:src="@drawable/ic_action_send_now_offline" /> Please be very careful with those Increase font size Use larger font sizes across the entire app + Send button indicates status + Colorize send button to indicate a contacs status \ No newline at end of file diff --git a/res/xml/preferences.xml b/res/xml/preferences.xml index f0d64e39c..47508c9e2 100644 --- a/res/xml/preferences.xml +++ b/res/xml/preferences.xml @@ -69,6 +69,11 @@ android:key="use_larger_font" android:title="@string/pref_use_larger_font" android:summary="@string/pref_use_larger_font_summary"/> + listAdapter; - private OnConversationUpdate onConvChanged = new OnConversationUpdate() { - - @Override - public void onConversationUpdate() { - runOnUiThread(new Runnable() { - - @Override - public void run() { - updateConversationList(); - if (paneShouldBeOpen) { - if (conversationList.size() >= 1) { - swapConversationFragment(); - } else { - startActivity(new Intent(getApplicationContext(), - StartConversationActivity.class)); - finish(); - } - } - ConversationFragment selectedFragment = (ConversationFragment) getFragmentManager() - .findFragmentByTag("conversation"); - if (selectedFragment != null) { - selectedFragment.updateMessages(); - } - } - }); - } - }; - protected ConversationActivity activity = this; private Toast prepareImageToast; @@ -602,7 +577,7 @@ public class ConversationActivity extends XmppActivity { this.onBackendConnected(); } if (conversationList.size() >= 1) { - onConvChanged.onConversationUpdate(); + this.onConversationUpdate(); } } @@ -610,6 +585,8 @@ public class ConversationActivity extends XmppActivity { protected void onStop() { if (xmppConnectionServiceBound) { xmppConnectionService.removeOnConversationListChangedListener(); + xmppConnectionService.removeOnAccountListChangedListener(); + xmppConnectionService.removeOnRosterUpdateListener(); } super.onStop(); } @@ -672,8 +649,9 @@ public class ConversationActivity extends XmppActivity { public void registerListener() { if (xmppConnectionServiceBound) { - xmppConnectionService - .setOnConversationListChangedListener(this.onConvChanged); + xmppConnectionService.setOnConversationListChangedListener(this); + xmppConnectionService.setOnAccountListChangedListener(this); + xmppConnectionService.setOnRosterUpdateListener(this); } } @@ -806,7 +784,65 @@ public class ConversationActivity extends XmppActivity { } public boolean forceEncryption() { - return PreferenceManager.getDefaultSharedPreferences( - getApplicationContext()).getBoolean("force_encryption", false); + return getPreferences().getBoolean("force_encryption", false); + } + + public boolean useSendButtonToIndicateStatus() { + return getPreferences().getBoolean("send_button_status", false); + } + + @Override + public void onAccountUpdate() { + final ConversationFragment fragment = (ConversationFragment) getFragmentManager() + .findFragmentByTag("conversation"); + if (fragment != null) { + runOnUiThread(new Runnable() { + + @Override + public void run() { + fragment.updateMessages(); + } + }); + } + } + + @Override + public void onConversationUpdate() { + runOnUiThread(new Runnable() { + + @Override + public void run() { + updateConversationList(); + if (paneShouldBeOpen) { + if (conversationList.size() >= 1) { + swapConversationFragment(); + } else { + startActivity(new Intent(getApplicationContext(), + StartConversationActivity.class)); + finish(); + } + } + ConversationFragment selectedFragment = (ConversationFragment) getFragmentManager() + .findFragmentByTag("conversation"); + if (selectedFragment != null) { + selectedFragment.updateMessages(); + } + } + }); + } + + @Override + public void onRosterUpdate() { + final ConversationFragment fragment = (ConversationFragment) getFragmentManager() + .findFragmentByTag("conversation"); + if (fragment != null) { + runOnUiThread(new Runnable() { + + @Override + public void run() { + fragment.updateMessages(); + } + }); + } } } diff --git a/src/eu/siacs/conversations/ui/ConversationFragment.java b/src/eu/siacs/conversations/ui/ConversationFragment.java index b73bcadbe..c6b129ad7 100644 --- a/src/eu/siacs/conversations/ui/ConversationFragment.java +++ b/src/eu/siacs/conversations/ui/ConversationFragment.java @@ -12,6 +12,7 @@ import eu.siacs.conversations.entities.Contact; import eu.siacs.conversations.entities.Conversation; import eu.siacs.conversations.entities.Message; import eu.siacs.conversations.entities.MucOptions; +import eu.siacs.conversations.entities.Presences; import eu.siacs.conversations.services.XmppConnectionService; import eu.siacs.conversations.ui.EditMessage.OnEnterPressed; import eu.siacs.conversations.ui.XmppActivity.OnPresenceSelected; @@ -61,6 +62,7 @@ public class ConversationFragment extends Fragment { protected String queuedPqpMessage = null; private EditMessage mEditMessage; + private ImageButton mSendButton; private String pastedText = null; private RelativeLayout snackbar; private TextView snackbarMessage; @@ -255,9 +257,8 @@ public class ConversationFragment extends Fragment { } }); - ImageButton sendButton = (ImageButton) view - .findViewById(R.id.textSendButton); - sendButton.setOnClickListener(this.mSendButtonListener); + mSendButton = (ImageButton) view.findViewById(R.id.textSendButton); + mSendButton.setOnClickListener(this.mSendButtonListener); snackbar = (RelativeLayout) view.findViewById(R.id.snackbar); snackbarMessage = (TextView) view.findViewById(R.id.snackbar_message); @@ -485,6 +486,7 @@ public class ConversationFragment extends Fragment { activity.getConversationList(), null, false); activity.updateConversationList(); } + this.updateSendButton(); } } @@ -497,6 +499,51 @@ public class ConversationFragment extends Fragment { updateChatMsgHint(); } + public void updateSendButton() { + Conversation c = this.conversation; + if (activity.useSendButtonToIndicateStatus() && c != null + && c.getAccount().getStatus() == Account.STATUS_ONLINE) { + if (c.getMode() == Conversation.MODE_SINGLE) { + switch (c.getContact().getMostAvailableStatus()) { + case Presences.ONLINE: + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_online); + break; + case Presences.AWAY: + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_away); + break; + case Presences.XA: + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_away); + break; + case Presences.DND: + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_dnd); + break; + default: + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_offline); + break; + } + } else if (c.getMode() == Conversation.MODE_MULTI) { + if (c.getMucOptions().online()) { + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_online); + } else { + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_offline); + } + } else { + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_offline); + } + } else { + this.mSendButton + .setImageResource(R.drawable.ic_action_send_now_offline); + } + } + protected void updateStatusMessages() { if (conversation.getMode() == Conversation.MODE_SINGLE) { for (int i = this.messageList.size() - 1; i >= 0; --i) {