Commit Graph

244 Commits

Author SHA1 Message Date
Vincent Sanders
f6f8102ecb clean up tab focus setting 2019-09-21 10:53:41 +01:00
Vincent Sanders
25581133a1 remove unused signal handler api 2019-09-21 10:53:41 +01:00
Vincent Sanders
2bed178a33 fix resource release and stopping throbber on toolbar widget destruction 2019-09-21 10:53:41 +01:00
Vincent Sanders
d94afaa0e1 make the gtk_search structure private to teh gtk search object 2019-09-21 10:53:41 +01:00
Vincent Sanders
e9b5b56ba6 fixup the gtk2 ui builders 2019-09-21 10:53:41 +01:00
Vincent Sanders
a013a24d5f clean up find in page to operate nicely 2019-09-21 10:53:41 +01:00
Vincent Sanders
a20fe23ce6 move search toolbar to be per tab and move implementation to one place 2019-09-21 10:53:41 +01:00
Vincent Sanders
9bbc7eb9cb ensure pixbuf references are updated correctly to avoid leaks 2019-09-21 10:53:41 +01:00
Vincent Sanders
541acda906 add cookie icon and use it for show cookies toolbar button 2019-09-21 10:53:41 +01:00
Vincent Sanders
11aa682154 construct all toolbar items from data table
This changes toolbar item constuction to use toolbar_items.h
  instead of explicit macros.

Additionally all remenants of old stock item themeing are done
  away with and GTK icon names are used instead.
2019-09-21 10:53:41 +01:00
Vincent Sanders
9cd9a403e6 do not allocate toolbar items individually 2019-09-21 10:53:41 +01:00
Vincent Sanders
3df34e7dec cleanup some toolbar item creation bits 2019-09-21 10:53:41 +01:00
Vincent Sanders
a8e186f120 fix customisation toolbar reset and remove unused code 2019-09-21 10:53:41 +01:00
Vincent Sanders
7b63f36a4f toolbar customisation can now apply chnages 2019-09-21 10:53:41 +01:00
Vincent Sanders
db558f862b fix dragging into customisation toolbar 2019-09-21 10:53:41 +01:00
Vincent Sanders
c7ad2553d8 allow toolbar customisation to remove widgets from the toolbar 2019-09-21 10:53:41 +01:00
Vincent Sanders
dbc5b5df6a fixup gtk2 ui builder for toolbar customisation 2019-09-21 10:53:41 +01:00
Vincent Sanders
df398ed886 populate toolbar customisation with icons 2019-09-21 10:53:41 +01:00
Vincent Sanders
778c05a194 populate customize window toolbar 2019-09-21 10:53:41 +01:00
Vincent Sanders
608cc3cbbf make handling of non browser window containing tabs reasonable 2019-09-21 10:53:41 +01:00
Vincent Sanders
747f135de5 make new browser window creation logic common 2019-09-21 10:53:41 +01:00
Vincent Sanders
fc4ad51a66 fix both gtk2 and 3 toolbar ui builder files 2019-09-21 10:53:41 +01:00
Vincent Sanders
c7c89daff3 allow toolbar customisation to open a tab 2019-09-21 10:53:41 +01:00
Vincent Sanders
46e1116aaa change toolbar customization to tab approach 2019-09-21 10:53:41 +01:00
Vincent Sanders
65d5161558 remove unsused junk gtk_history_window structure and functions 2019-09-21 10:53:41 +01:00
Vincent Sanders
635be1dfb8 make toolbar and menubar hiding work appropriately 2019-09-21 10:53:41 +01:00
Vincent Sanders
bcb2b7a2c4 simplify toolbar items macros 2019-09-21 10:53:41 +01:00
Vincent Sanders
1119707410 add toolbar customize to main and burger menu 2019-09-21 10:53:41 +01:00
Vincent Sanders
5f5b94c2ae simplify menu initialisation macros 2019-09-21 10:53:41 +01:00
Vincent Sanders
061499eef6 set menu activation handler using toolbar items 2019-09-21 10:53:41 +01:00
Vincent Sanders
64b2f355dc use toolbar_items to generate more boilerplate code through macros 2019-09-21 10:53:41 +01:00
Vincent Sanders
ec62f346e1 fix toolbar property update 2019-09-21 10:53:41 +01:00
Vincent Sanders
f6a669464f split burger menu from popup context menu 2019-09-21 10:53:41 +01:00
Vincent Sanders
85b65921ed cleanup scaffolding a bit 2019-09-21 10:53:41 +01:00
Vincent Sanders
2e8861dc05 make web search icon setting work properly 2019-09-21 10:53:41 +01:00
Vincent Sanders
e84990bc89 make popup context menu work on toolbar 2019-09-21 10:53:41 +01:00
Vincent Sanders
e36338b617 complete toolbar button click handler implementation 2019-09-21 10:53:41 +01:00
Vincent Sanders
08d7c55cc5 another five handlers and fix menu sensitivity on throbber state change 2019-09-21 10:53:41 +01:00
Vincent Sanders
45bd456cd8 add five more handlers 2019-09-21 10:53:41 +01:00
Vincent Sanders
7f115dc926 implemented another seven signal handlers 2019-09-21 10:53:41 +01:00
Vincent Sanders
8f0c0734ea implement more toolbar item handlers and make menus call them 2019-09-21 10:53:41 +01:00
Vincent Sanders
8eebe695f0 allow menu activation to use the toolbar button implementations 2019-09-21 10:53:41 +01:00
Vincent Sanders
b24b28e40e clean up some more handler code and remove button push 2019-09-21 10:53:41 +01:00
Vincent Sanders
ff64341ed3 make menu sensitivity work
what remains is interfaces to make the toolbar appropriately sensative
2019-09-21 10:53:41 +01:00
Vincent Sanders
c297101c3a make menus work again 2019-09-21 10:53:41 +01:00
Vincent Sanders
b389dd4116 make web search box work 2019-09-21 10:53:41 +01:00
Vincent Sanders
f3a68771e3 add home button clicked handler 2019-09-21 10:53:41 +01:00
Vincent Sanders
305190fe73 implement several more button press handlers 2019-09-21 10:53:41 +01:00
Vincent Sanders
07a9d5b3fb connect button clicked events for local history and stop buttons 2019-09-21 10:53:41 +01:00
Vincent Sanders
8b5100a97e fix url enttry completion 2019-09-21 10:53:41 +01:00
Vincent Sanders
869c16dae6 cleanup toolbar warnings 2019-09-21 10:53:41 +01:00
Vincent Sanders
bd90138b48 make url entry repond to navigate and update signals 2019-09-21 10:53:41 +01:00
Vincent Sanders
dd767acfee make toolbar url entry display url 2019-09-21 10:53:41 +01:00
Vincent Sanders
02c75d0790 working throbber 2019-09-21 10:53:41 +01:00
Vincent Sanders
89fb88f6de move toolbar to be in tab contents 2019-09-21 10:53:41 +01:00
Vincent Sanders
65d169da10 get the code to at least compile again. toolbar is completely broken 2019-09-21 10:53:41 +01:00
Vincent Sanders
1fc51d1f44 moved most of init to toolbar.c 2019-09-21 10:53:41 +01:00
Vincent Sanders
6bce06b91f fix spelling mistakes from miscellaneous event commit 2019-08-20 16:38:51 +01:00
Vincent Sanders
4dc4d8b318 add miscellaneous event to browser window callback table
extend the browser window callback table with a miscallaneous event
 entry. This is used to replace all browser window callbacks which
 take no parameters.

This reduces the API surface from seven separate calls to a single
 call with an enumeration which may be readily extended.

The initial implementation in the frontends simply calls the original
 implementations to reduce scope for errors.
2019-08-20 00:16:52 +01:00
Vincent Sanders
c0e27bd0da access gtk throbber frames through an interface
This changes the gtk throbber frames to be accessed through an API
  This removes teh nsgtk_throbber global and hides the implementation
  details from the rest of the code.
2019-08-18 14:41:31 +01:00
Vincent Sanders
01f3879b64 Move favicon from url entry widget to notebook tab label 2019-08-15 23:02:04 +01:00
Vincent Sanders
6a1dbd377b
remove login window from gtk front end 2019-08-13 12:09:21 +01:00
Daniel Silverstone
1cf1ec55bc Support SSL verification through new about: handler
In doing this, also propagate why the certificates were bad
so that the page can display a reason.  We will need FatMessages
for all these.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-08-06 13:15:23 +01:00
Daniel Silverstone
8469f4cc8e Reimplement handling of BAD_AUTH inside browser_window
We now handle authentication requests via an `about:` page
which presents a nice form built into the browser window.
In order to do this, we add internal navigation as a concept
to the browser window and we strip the 401login support from all
frontends except monkey.

The 401login callback is now intended for password safe type support
rather than an immediately interactive prompt.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-08-06 11:26:47 +01:00
Vincent Sanders
337c2ed7b1 remove unused gtk window interfaces and clean up documentation 2019-08-04 09:47:58 +01:00
Michael Drake
3938d5340b Corewindow: Sanitise scrolling API.
Now the core has a helper so that all the front ends don't need
to implement the scroll to show area API.

Now they simply have get and set scroll APIs.
2019-08-03 15:57:23 +01:00
Vincent Sanders
641f5fb072 make use of improved browser_window_set_scale API in frontends 2019-08-03 15:53:07 +01:00
Vincent Sanders
d4c01894c2 change browser_window_get_features to use unscaled coordinates 2019-08-03 14:29:06 +01:00
Vincent Sanders
0ebfff259f change browser_window_mouse_track to use unscaled coordinates 2019-08-03 14:29:05 +01:00
Vincent Sanders
0a8ed41a1a change browser_window_mouse_click to use unscaled coordinates
this means frontends no longer need to scale mouse click events thus
simplifying their implementation.
2019-08-03 14:29:05 +01:00
Daniel Silverstone
5e8b2d4653 gtk/local_history: Scroll local history to cursor on display
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-08-02 21:00:34 +01:00
Daniel Silverstone
c078c3f509 gtk/corewindow.c: Correctly handle scroll_visible
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-08-02 21:00:06 +01:00
Daniel Silverstone
6bbdf08cb0 gtk, beos: Run scheduler before fetching fdset
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-08-02 17:06:45 +01:00
Vincent Sanders
552aab42e1 remove scaled parameter from get_dimensions 2019-08-02 12:26:20 +01:00
Michael Drake
2943e9ae46 GTK: Update for unscaled bw invalidate rectangle. 2019-08-01 22:34:13 +01:00
Vincent Sanders
5742762070 split browser and browser_window operations 2019-08-01 19:51:19 +01:00
Samuel Dionne-Riel
87177d8aa1 GTK: prefer using curl's intrinsic defaults for CURLOPT_CA*
On distributions that ship only a ca-bundle in `/etc/ssl`, the
configuration set at initialization will force curl to look for
certificates that are not present in this directory.

Removing the setting instead makes curl use its internal default.

The framebuffer frontend will not set this option, and the only
other frontend that sets it is BeOS.

This issue can be observed (likely among other) on the NixOS Linux
distribution.
2019-08-01 12:03:06 +01:00
brabo
ba9f5f8ef0 gtk/fetch.c & monkey/filetype.c: ascii_is_space already checks for newline. 2019-08-01 10:42:08 +01:00
brabo
c90bfb23ad gtk/fetch.c & monkey/filetype.c: small comment correction. 2019-08-01 10:42:08 +01:00
Michael Forney
6a53b447e5 Declare global variables as extern in headers
Otherwise, each source file that includes the header will create a
new definition, which are usually merged together by the linker.

Multiple definitions of an object is not allowed in ISO C.
2019-06-30 09:52:06 +01:00
Vincent Sanders
dddc5eac94 Update schedulers return codes
The GTK and monkey frontends schedulers now return NSERROR_NOT_FOUND
 when a caller is using a negative schedule time to remove a callback.
2019-06-08 13:33:16 +01:00
Vincent Sanders
35bc2ccbb8 change content get_source_data interfaces to return uint8_t and size_t
previously these interfaces returned char * and unsigned int which was
undesirable.
2019-05-05 22:50:25 +01:00
Vincent Sanders
efdea7757b fix enum name incompatability between gtk 2 and 3 2019-05-05 15:38:19 +01:00
Vincent Sanders
6ff3238825 centralise monkey output generation 2018-11-03 15:12:50 +00:00
Michael Drake
96254254a6 GTK: Squash GCC8.2 warning.
frontends/gtk/download.c: In function ‘gui_download_window_create’:
frontends/gtk/download.c:829:10: warning: cast between incompatible function types from ‘gboolean (*)(gboolean)’ {aka ‘int (*)(int)’} to ‘gboolean (*)(void *)’ {aka ‘int (*)(void *)’} [-Wcast-function-type]
          (GSourceFunc) nsgtk_download_update, FALSE);
          ^
2018-11-03 11:00:09 +00:00
Michael Drake
5eb7345cc7 GTK: Make nsgtk_download_selection_action match GFunc prototype.
Squashes GCC 8.2 warning:

frontends/gtk/download.c:244:22: warning: cast between incompatible function types
from ‘nsgtk_download_selection_action’ {aka ‘void (*)(struct gui_download_window *)’}
to ‘void (*)(void *, void *)’ [-Wcast-function-type]
  g_list_foreach(dls, (GFunc)action, NULL);
                      ^
2018-11-03 08:48:24 +00:00
Michael Drake
df79047cb6 GTK: Squash a couple of warnings from GCC 8.2.
frontends/gtk/download.c: In function ‘nsgtk_download_do’:
frontends/gtk/download.c:238:24: warning: cast between incompatible function
types from ‘void (*)(GtkTreePath *)’ {aka ‘void (*)(struct _GtkTreePath *)’}
to ‘void (*)(void *, void *)’ [-Wcast-function-type]
   g_list_foreach(rows, (GFunc)gtk_tree_path_free, NULL);
                        ^
frontends/gtk/download.c:239:24: warning: cast between incompatible function
types from ‘void (*)(void *)’ to ‘void (*)(void *, void *)’ [-Wcast-function-type]
   g_list_foreach(rows, (GFunc)g_free, NULL);
                        ^
2018-11-03 08:39:05 +00:00
Vincent Sanders
8687265c9a fix stupid typo in previous commit 2018-10-08 12:33:58 +01:00
Vincent Sanders
a8ee1c2d63 explicitly check for null string before compare 2018-10-06 15:44:17 +01:00
Vincent Sanders
83512a6ff5 squash clang warning about increased alignment requirements. 2018-09-26 17:21:05 +01:00
Vincent Sanders
2596331640 seems freebsd needs _XOPEN_SOURCE for math.h macros to be defined 2018-09-06 12:10:38 +01:00
Vincent Sanders
6ce6b62099 stop defining _XOPEN_SOURCE
This is necessary with some libc as it overrides _POSIX_C_SOURCE
and removes definitions of scandir etc.
2018-09-06 11:33:02 +01:00
Vincent Sanders
9142bab736 remove a warning on openbsd 2018-08-28 22:17:02 +01:00
Michael Drake
d54e0461ad GTK: Remove logging during window resize. 2018-08-27 20:04:24 +01:00
Vincent Sanders
487309a1e6 fixup usage of gvalue init macro 2018-08-26 11:22:20 +01:00
Vincent Sanders
4765c68a15 fix gtk 3 deprication warnings 2018-08-26 10:12:35 +01:00
Vincent Sanders
f4620a3f68 remove depricated gtk 3 interfaces 2018-08-24 20:25:14 +01:00
Vincent Sanders
2f663987c5 do not use strlen as a variable name 2018-08-21 14:59:29 +01:00
Vincent Sanders
650ac58604 Improve GTK login dialog 2018-08-19 23:16:16 +01:00
Michael Drake
6144993c8a GTK: Update for new HTTP auth API. 2018-08-15 07:19:58 +01:00