summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autocomplete/autocomplete_edit_view_gtk.h
diff options
context:
space:
mode:
authorestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-09 03:03:42 +0000
committerestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-09 03:03:42 +0000
commit50650fa2691fb199ad624bb9b704cf9f0ae1d992 (patch)
tree132c5fcffcdce00db2a4a216d5a675a557ba002b /chrome/browser/autocomplete/autocomplete_edit_view_gtk.h
parent77565b692802c8f9a8ac043bcebaed0dee32cec8 (diff)
downloadchromium_src-50650fa2691fb199ad624bb9b704cf9f0ae1d992.zip
chromium_src-50650fa2691fb199ad624bb9b704cf9f0ae1d992.tar.gz
chromium_src-50650fa2691fb199ad624bb9b704cf9f0ae1d992.tar.bz2
GTK: Draw a strikethrough over bad https.
TEST=https://metafilter.com BUG=23339 Review URL: http://codereview.chromium.org/261033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28510 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autocomplete/autocomplete_edit_view_gtk.h')
-rw-r--r--chrome/browser/autocomplete/autocomplete_edit_view_gtk.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit_view_gtk.h b/chrome/browser/autocomplete/autocomplete_edit_view_gtk.h
index 3f5c87a..02c619e 100644
--- a/chrome/browser/autocomplete/autocomplete_edit_view_gtk.h
+++ b/chrome/browser/autocomplete/autocomplete_edit_view_gtk.h
@@ -10,6 +10,7 @@
#include <string>
#include "base/basictypes.h"
+#include "base/gfx/rect.h"
#include "base/scoped_ptr.h"
#include "base/string_util.h"
#include "chrome/browser/autocomplete/autocomplete_edit_view.h"
@@ -280,6 +281,18 @@ class AutocompleteEditViewGtk : public AutocompleteEditView,
}
void HandlePasteClipboard();
+ static gboolean HandleExposeEventThunk(GtkTextView* text_view,
+ GdkEventExpose* expose,
+ gpointer self) {
+ return reinterpret_cast<AutocompleteEditViewGtk*>(self)->
+ HandleExposeEvent(expose);
+ }
+ gboolean HandleExposeEvent(GdkEventExpose* expose);
+
+ // Gets the GTK_TEXT_WINDOW_WIDGET coordinates for |text_view_| that bound the
+ // given iters.
+ gfx::Rect WindowBoundsFromIters(GtkTextIter* iter1, GtkTextIter* iter2);
+
// Actual implementation of SelectAll(), but also provides control over
// whether the PRIMARY selection is set to the selected text (in SelectAll(),
// it isn't, but we want set the selection when the user clicks in the entry).
@@ -413,6 +426,11 @@ class AutocompleteEditViewGtk : public AutocompleteEditView,
// handled by IME or not.
bool enter_was_inserted_;
+ // Contains the character range that should have a strikethrough (used for
+ // insecure schemes). If the range is size one or less, no strikethrough
+ // is needed.
+ CharRange strikethrough_;
+
DISALLOW_COPY_AND_ASSIGN(AutocompleteEditViewGtk);
};