termio{,link}: correct check + remove useless 'if'

This commit is contained in:
Boris Faure 2020-06-15 23:08:52 +02:00
parent 548027a656
commit 50de16cca2
Signed by: borisfaure
GPG Key ID: 35C0410516166BE8
2 changed files with 9 additions and 9 deletions

View File

@ -1124,7 +1124,7 @@ _cb_ctxp_color_copy(void *data,
EINA_SAFETY_ON_NULL_RETURN(sd);
txt = _color_to_txt(sd);
if (!sd) return;
if (!txt) return;
termio_take_selection_text(sd, ELM_SEL_TYPE_CLIPBOARD, txt);

View File

@ -1385,14 +1385,14 @@ _sharp_color_find(Termpty *ty, int sc,
ty_sb_free(&sb);
if (found)
{
if (rp) *rp = r;
if (gp) *gp = g;
if (bp) *bp = b;
if (ap) *ap = a;
if (x1r) *x1r = x1;
if (y1r) *y1r = y1 + sc;
if (x2r) *x2r = x2;
if (y2r) *y2r = y2 + sc;
*rp = r;
*gp = g;
*bp = b;
*ap = a;
*x1r = x1;
*y1r = y1 + sc;
*x2r = x2;
*y2r = y2 + sc;
}
return found;
}