Check-in [a8fe9cd4db]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Show avatar only when known
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: a8fe9cd4db2abd474dcdeeb1ea3d3a34c4a7efec
User & Date: bernd 2019-11-22 18:49:08.969
Context
2019-11-26
20:35
Background-load avatar image if not available check-in: e426aee2a6 user: bernd tags: trunk
2019-11-22
18:49
Show avatar only when known check-in: a8fe9cd4db user: bernd tags: trunk
2019-11-21
22:44
Fixes for problems found today check-in: 82cb1e9136 user: bernd tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to gui.fs.
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447

glue new Constant glue*avatar
glue*avatar >o pixelsize# 64 fm* 0e 0g glue-dup hglue-c glue! vglue-c glue! 0glue dglue-c glue! o>

: read-avatar ( addr u -- addr' u' )
    ?read-enc-hashed mem>thumb atlas-region ;
: show-avatar ( addr u -- o )
    2dup avatar# #@ nip 0= IF
	2dup read-avatar 2swap avatar# #!
    ELSE  2drop  THEN
    glue*avatar last# cell+ $@ drop }}thumb
    >r {{ r> }}v 40%b ;

: re-avatar ( last# -- )
    >r r@ $@ read-avatar r> cell+ $@ smove ;

:noname defers free-thumbs
    avatar# ['] re-avatar #map ; is free-thumbs








|
|
|
|
|







429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447

glue new Constant glue*avatar
glue*avatar >o pixelsize# 64 fm* 0e 0g glue-dup hglue-c glue! vglue-c glue! 0glue dglue-c glue! o>

: read-avatar ( addr u -- addr' u' )
    ?read-enc-hashed mem>thumb atlas-region ;
: show-avatar ( addr u -- o )
    [: 2dup avatar# #@ nip 0= IF
	    2dup read-avatar 2swap avatar# #!
	ELSE  2drop  THEN
	glue*avatar last# cell+ $@ drop }}thumb
	>r {{ r> }}v 40%b ;] catch IF  2drop  THEN ;

: re-avatar ( last# -- )
    >r r@ $@ read-avatar r> cell+ $@ smove ;

:noname defers free-thumbs
    avatar# ['] re-avatar #map ; is free-thumbs

Changes to msg.fs.
1
2
3
4
5
6
7
8
9
10
\ messages                                           06aug2014py

\ Copyright © 2014-2016   Bernd Paysan

\ This program is free software: you can redistribute it and/or modify
\ it under the terms of the GNU Affero General Public License as published by
\ the Free Software Foundation, either version 3 of the License, or
\ (at your option) any later version.

\ This program is distributed in the hope that it will be useful,


|







1
2
3
4
5
6
7
8
9
10
\ messages                                           06aug2014py

\ Copyright © 2014-2019   Bernd Paysan

\ This program is free software: you can redistribute it and/or modify
\ it under the terms of the GNU Affero General Public License as published by
\ the Free Software Foundation, either version 3 of the License, or
\ (at your option) any later version.

\ This program is distributed in the hope that it will be useful,