[Commits] [SCM] claws branch, master, updated. 4.1.1-101-gd4170e674

jonathan at claws-mail.org jonathan at claws-mail.org
Sun Oct 22 11:51:52 UTC 2023


The branch, master has been updated
       via  d4170e674a04910babb0e592e93441f5af53429f (commit)
      from  fd6149254aaebd40e2ac74d8c2c6f1a54d71d0f3 (commit)

Summary of changes:
 src/plugins/litehtml_viewer/lh_widget.cpp | 16 +---------------
 src/plugins/litehtml_viewer/lh_widget.h   |  1 -
 2 files changed, 1 insertion(+), 16 deletions(-)


- Log -----------------------------------------------------------------
commit d4170e674a04910babb0e592e93441f5af53429f
Author: Jonathan Boeing <jonathan at claws-mail.org>
Date:   Tue Oct 10 00:09:12 2023 -0700

    Sync with api changes

diff --git a/src/plugins/litehtml_viewer/lh_widget.cpp b/src/plugins/litehtml_viewer/lh_widget.cpp
index 984422c7f..f06834d0e 100644
--- a/src/plugins/litehtml_viewer/lh_widget.cpp
+++ b/src/plugins/litehtml_viewer/lh_widget.cpp
@@ -375,20 +375,6 @@ const char *lh_widget::get_href_at(litehtml::element::ptr element) const
 	return el->get_attr("href");
 }
 
-const char *lh_widget::get_href_at(const gint x, const gint y) const
-{
-	litehtml::element::ptr over_el, el;
-
-	if (m_html == NULL)
-		return NULL;
-
-	over_el = m_html->root()->get_element_by_point(x, y, x, y);
-	if (over_el == NULL)
-		return NULL;
-
-	return get_href_at(over_el);
-}
-
 void lh_widget::print()
 {
     debug_print("lh_widget print\n");
@@ -512,7 +498,7 @@ static gboolean button_press_event(GtkWidget *widget, GdkEventButton *event,
 
 	/* Right-click */
 	if (event->button == 3) {
-		const char *url = w->get_href_at((gint)event->x, (gint)event->y);
+		const char *url = w->get_href_at(w->m_html->over_element());
 
 		if (url != NULL)
 			w->popup_context_menu(url, event);
diff --git a/src/plugins/litehtml_viewer/lh_widget.h b/src/plugins/litehtml_viewer/lh_widget.h
index c1a1d4957..b19d6d591 100644
--- a/src/plugins/litehtml_viewer/lh_widget.h
+++ b/src/plugins/litehtml_viewer/lh_widget.h
@@ -60,7 +60,6 @@ class lh_widget : public container_linux
 		void print();
 
 		const char *get_href_at(litehtml::element::ptr element) const;
-		const char *get_href_at(const gint x, const gint y) const;
 		void popup_context_menu(const char *url, GdkEventButton *event);
 		const litehtml::string fullurl(const char *url) const;
 

-----------------------------------------------------------------------


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list