Skip to content

Commit abb5060

Browse files
Piiitclefebvre
authored andcommitted
Fix for 'Inverted Colors won't be saved by Save Current Settings as Default' (#142)
Fixes #38 The web-view callback for inverted colors got called, and if it did not find a web-view open it defaulted to FALSE for inverted colors.
1 parent e76a18d commit abb5060

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

libview/ev-web-view.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,10 @@ ev_web_view_inverted_colors_changed_cb (EvDocumentModel *model,
252252
EvWebView *webview)
253253
{
254254
EvDocument *document = ev_document_model_get_document(model);
255-
255+
256+
if (!document || !document->iswebdocument)
257+
return;
258+
256259
if (ev_document_model_get_inverted_colors(model) == TRUE) {
257260
if (document == NULL) {
258261
ev_document_model_set_inverted_colors(model,FALSE);

0 commit comments

Comments
 (0)