diff options
author | Jörg Frings-Fürst <debian@jff.email> | 2018-09-30 14:09:20 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff.email> | 2018-09-30 14:09:20 +0200 |
commit | 5e9f4eea451a77ba3b93db3747841ed2bd969e9f (patch) | |
tree | 75046a38ca68975261d853a2e56ff7bf6b3e1daa /src/util/image.vala | |
parent | 18b52c2983a1b3409011f72d27f15de576c5eb1c (diff) |
New upstream version 0.30.1upstream/0.30.1
Diffstat (limited to 'src/util/image.vala')
-rw-r--r-- | src/util/image.vala | 121 |
1 files changed, 5 insertions, 116 deletions
diff --git a/src/util/image.vala b/src/util/image.vala index f8646e2..0a30339 100644 --- a/src/util/image.vala +++ b/src/util/image.vala @@ -4,121 +4,6 @@ * See the COPYING file in this distribution. */ - -/* XPM */ -private const string fallback_image_missing[] = { -/* columns rows colors chars-per-pixel */ -"48 48 54 1 ", -" c #6A6D67", -". c #6C6E69", -"X c #72746F", -"o c #747672", -"O c #777974", -"+ c #797B77", -"@ c #7C7E7A", -"# c #7F817C", -"$ c #81837F", -"% c #848682", -"& c #878984", -"* c #888A86", -"= c #8C8D8A", -"- c #8F908C", -"; c #90928E", -": c #949591", -"> c #969894", -", c #999B96", -"< c #9C9E9A", -"1 c #9FA09C", -"2 c #A1A39E", -"3 c #A4A6A2", -"4 c #A6A9A4", -"5 c #A9ABA6", -"6 c #ACADA9", -"7 c #AEB1AB", -"8 c #B1B2AF", -"9 c #B3B4B1", -"0 c #B6B9B3", -"q c #B9BCB6", -"w c #BDBEBA", -"e c #BEC2BB", -"r c #C1C4BE", -"t c #C5C5C2", -"y c #C6C9C3", -"u c #C9CCC6", -"i c #CCCDCB", -"p c #CED2CA", -"a c #D2D6CE", -"s c #D5D5D3", -"d c #D7D8D5", -"f c #D9D9D6", -"g c #DCDCDA", -"h c #DFE0DD", -"j c #E0E0DE", -"k c #E4E4E2", -"l c #E7E8E5", -"z c #E9E9E7", -"x c #EDEDEC", -"c c #EFF0EE", -"v c #F1F1EF", -"b c #F2F2F1", -"n c #FFFFFF", -"m c None", -/* pixels */ -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmaaaaaaaaaasaisaaaaaaaaaaaaaaaaaaapppiipuuuuumm", -"mannnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnym", -"manbbbbbbbbbvbbvvvvxvvvbvvvvvvvvccccccxxvxvxxnym", -"manbt89898888988888888888999999999999999999txnrm", -"manb6======================-;;=;;;;;;;;;;=:7znrm", -"manv6&%%**%*%%%%*%%****=======;==;;;;=;=;==7znem", -"manv4%%%%$%%%%%%%%%%%=****=======;==-======6znwm", -"manx3%%#$$$$##%#$%%%*%**==========-=--=====6znqm", -"manx1$@%#$@$###%%%%=****=*===--;;----====*=5lnqm", -"manx<@@@@@@@@##%$%%%%****========-==-======5kn0m", -"manz<@@@+@+@@@#$%%%%%=%=%===;=:=--------=-*4kn8m", -"manz>O+O+O+@@@#$$%%%%========;;=--------=*=3kn9m", -"mpnl:OOOOO+@@$##%%%%%=%=====;=;;--;-----===3kn8m", -"munl;OooOOO@@@#$%%%%%======;;;;;:;;;;;---==1hn7m", -"munl;oXoOO+@###$%%=%=======;::;::::;;---&#+-gn7m", -"mynk*XXooOO+$$#$%%%%=%===;;:;:::::;:-$#XooX-fn5m", -"mynk*XXOOO@@$$$$%%=%====;::::>::;*#OXXXXXXX*dn5m", -"mrnk*oOO@@@#$$$$%=====::::>>>=%@OXOooXXXooo&dn3m", -"mrnj*++@$$$$**$===-;;::>>:=@Ooo@XOOoo#o#OOO=fn3m", -"menj*@#$$$$$**===;;:::=%@@@@@@O@#O#Oo#o#++@;gn2m", -"menj*$$$$&**===;:;=*#@@@@@@@@@@@#######o##%>gn2m", -"menh*$$%**===;=*%###########%@@@###$####$%=,gn1m", -"m0nj=%***=**&$$$%$$$%$$%$$$$%$$$$$$$$$$%*;:2hn<m", -"m0nj****&&&$$&&$%%%%%%%%%%%%%%%%$$*$%%%*;>13gn,m", -"m0ng****&&&&&&&&&&&&*%*%*%%*%******%**-:,136kz;m", -"m0nh***$&&&&&&&&&&&&%**********%*$***;:,1358r7*m", -"m8ng*&&&&&&&&&*$&*&&&&$=$=$=&&&&&&**=:,<11>$65mm", -"m7ng*&&&&&&&&&**&&&&&&**=$-$&&&&&&*-:,1..&1wi:mm", -"m7ng&&&&&&&&=$*$&&&&&***$$$$&&&***=>,1<onxsi6*mm", -"m6nf*&&&&&*&$***&&&&*$*$--$-&&&%*=;,13,:ztw9%mmm", -"m5nf*%&&&&&&=$=$%*&&**%*$$&&&&**=>,225;5srw%mmmm", -"m4nf3*&&**&&$-$-*******%$;&&*&*->,2365+ui7$mmmmm", -"m3nsfffdddsddaffssssdassgaaaassddfgjg4wu;ommmmmm", -"m3nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnvq3<$.mmmmmmm", -"mm2211111,<,,,,,,>>>>:::;::;----=====@mmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", -"mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm" -}; - -bool is_color_parsable(string spec) { - var color = Gdk.RGBA (); - return color.parse(spec); -} - Gdk.RGBA parse_color(string spec) { return fetch_color(spec); } @@ -148,7 +33,11 @@ Gdk.Pixbuf get_placeholder_pixbuf () { pixbuf = icon_theme.load_icon("image-missing", Gtk.IconSize.DIALOG, 0); } catch (Error error) { - pixbuf = new Gdk.Pixbuf.from_xpm_data(fallback_image_missing); + try { + pixbuf = new Gdk.Pixbuf.from_resource("/org/gnome/Shotwell/icons/image-missing.png"); + } catch (Error err) { + warning("Could not load fall-back icon: %s", err.message); + } warning("Could not load icon from theme: %s", error.message); } |