Daniel Carl [Wed, 14 Jun 2017 20:10:04 +0000 (22:10 +0200)]
Use web context of the webview instead of default.
This should not make any difference at the time but we are free to use
custom web context later.
Daniel Carl [Tue, 13 Jun 2017 20:41:27 +0000 (22:41 +0200)]
Keep xid generation and setting to env close together.
Daniel Carl [Tue, 13 Jun 2017 20:22:19 +0000 (22:22 +0200)]
Don't set window size if embedded #417.
In case vimb is embedded the window size is determined by the embedding
application. Setting the default window size in this case caused screen
redraw issue so that statusbar was not updated properly.
Daniel Carl [Thu, 8 Jun 2017 22:26:24 +0000 (00:26 +0200)]
Lower required webkit version #415.
Daniel Carl [Thu, 8 Jun 2017 22:05:41 +0000 (00:05 +0200)]
Don't limit web processes to one.
Daniel Carl [Mon, 5 Jun 2017 22:14:06 +0000 (00:14 +0200)]
Fixed unused function parameter.
Daniel Carl [Fri, 2 Jun 2017 22:48:27 +0000 (00:48 +0200)]
Don't recompile all objects in scripts change.
Daniel Carl [Fri, 2 Jun 2017 21:22:19 +0000 (23:22 +0200)]
Remove also desktop file on uninstall.
Daniel Carl [Fri, 2 Jun 2017 21:17:44 +0000 (23:17 +0200)]
Adapt comment to fit the js2h logic.
Daniel Carl [Tue, 30 May 2017 21:22:36 +0000 (23:22 +0200)]
Remove duplicate call to webkit_uri_request_get_uri.
Daniel Carl [Tue, 30 May 2017 21:18:39 +0000 (23:18 +0200)]
Remove function parameter to embed new spawned instances.
All calls used the embed flag so this can be removed.
Daniel Carl [Tue, 30 May 2017 21:14:45 +0000 (23:14 +0200)]
Free memory of pid string.
Daniel Carl [Fri, 26 May 2017 21:56:23 +0000 (23:56 +0200)]
Released version 3.0-alpha.
Daniel Carl [Fri, 26 May 2017 22:11:00 +0000 (00:11 +0200)]
Merge branch 'webkit2'.
Daniel Carl [Fri, 26 May 2017 21:54:51 +0000 (23:54 +0200)]
Update license year.
Daniel Carl [Fri, 26 May 2017 21:34:17 +0000 (23:34 +0200)]
Removed no_proxy from man.
This is not done by vimb at the time because the proxy stuff is done by
webkit itself.
Daniel Carl [Wed, 24 May 2017 19:43:02 +0000 (21:43 +0200)]
Set window default size.
Daniel Carl [Wed, 24 May 2017 19:04:32 +0000 (21:04 +0200)]
Add :clearcache command.
This allows to discard all caches currently used by webkit.
Daniel Carl [Wed, 24 May 2017 18:42:30 +0000 (20:42 +0200)]
Removed hard coded tls policy.
The policy is already set during setting initialization.
Daniel Carl [Tue, 23 May 2017 21:17:40 +0000 (23:17 +0200)]
Sort changed settings.
Daniel Carl [Tue, 23 May 2017 21:09:57 +0000 (23:09 +0200)]
Added hardware acceleration to man page.
Daniel Carl [Tue, 23 May 2017 20:45:06 +0000 (22:45 +0200)]
Use dashed naming for user-agent too.
Daniel Carl [Tue, 23 May 2017 20:29:11 +0000 (22:29 +0200)]
Change default user-agent.
Use the user-agent that would be created by
webkit_settings_set_user_agent_with_application_details.
Daniel Carl [Sat, 20 May 2017 23:58:54 +0000 (01:58 +0200)]
Stop hinting when element clicked by mouse.
In case a links was clicked by mouse during active hinting, the new page
was loaded and kept still in hinting mode but there where no hints shown
on the new page.
Daniel Carl [Sat, 20 May 2017 23:55:03 +0000 (01:55 +0200)]
Don't handle hint in new window by javascript.
There are a lot of restrictions that introduces some hacks to allow to
open hints into new window. The hinting script does now only fire the
hints in case of ;o and ;t hinting and the decision where to open the
navigation decision is met in the c layer.
Daniel Carl [Sat, 20 May 2017 22:32:20 +0000 (00:32 +0200)]
Don't attempt to open empty url by hinting.
There are pages where following links are used <a href="#"
onclick="...">...</a>. In this special case of href="#" the elements
should be clicked to let webkit decide how to handle the element instead
of opening current page with appended location mark.
Daniel Carl [Sat, 20 May 2017 22:18:53 +0000 (00:18 +0200)]
Merge branch 'pks/hints-without-js' of https://github.com/pks-t/vimb into webkit2
Daniel Carl [Sat, 20 May 2017 22:04:27 +0000 (00:04 +0200)]
Merge branch 'pks/scroll-page' of https://github.com/pks-t/vimb into webkit2
Daniel Carl [Sat, 20 May 2017 22:01:06 +0000 (00:01 +0200)]
Merge branch 'pks/acceleration-settings' of https://github.com/pks-t/vimb into webkit2
Daniel Carl [Sat, 20 May 2017 21:55:02 +0000 (23:55 +0200)]
Merge branch 'pks/clear-scripts' of https://github.com/pks-t/vimb into webkit2
Patrick Steinhardt [Sat, 20 May 2017 16:56:18 +0000 (18:56 +0200)]
hints: do not execute `click` in addition to opening hints
When the element which we are about to open has a "href" attribute, we
will execute either `window.open` or set the `window.location.href`
attribute to the target's reference. But as we forgot to call `return`
here, we will also execute the code to open elements without "href"
attribute. In the case of opening a new window, we will now first open
the new window and then also set the current window's URL to the target,
which is obviously wrong.
Fix the issue by putting the excution of `click()` inside an
else-branch.
Patrick Steinhardt [Sat, 20 May 2017 16:49:08 +0000 (18:49 +0200)]
hints: use `window.location.href` to change current URL
When opening a hint in the current window, we do so by emulating a
`click()` on the element that we want to switch to. This enables us to
open hints when there is no href set, e.g. when the element executes
JavaScript to change the page. Unfortunately, this method of opening
links does not work when JavaScript is disabled in the client.
If the element has a `href` attribute, we can work around this problem
by directly setting `window.location.href` to the element's reference.
Next to being a more obvious method of setting the current URL, this
also fixes hints with JavaScript disabled. Note that we still have to
keep around the old method of using `click()` on the element in case it
has no href attribute.
Patrick Steinhardt [Sat, 20 May 2017 15:35:44 +0000 (17:35 +0200)]
scroll: fix percent-based scrolling
Scrolling via ^D and ^U should scroll by a percentage of the client's
current viewport. We do this in JavaScript via the client height of the
document's element. Accidentally, it may hold the desired value in some
cases, but in general it only holds the total height of the element
itself. What we desire instead is the window's height, which can be
retrieved via `Window.innerHeight`. Like this, our calculations are not
based upon the webpage but instead on the browser window, fixing
scrolling on some pages.
Patrick Steinhardt [Sat, 20 May 2017 10:25:25 +0000 (12:25 +0200)]
setting: expose hardware acceleration settings
Previous to the migration to the WebKit 2 API, we were exposing settings
to enable hardware acceleration for compositing via
"accelerated-compositing". With WebKit 2, there are two relevant
settings to enable compositing. The "hardware-acceleration_policy" is
used to determine when the rendering process should actually use
hardware acceleration. "accelerated-2d-canvas" enables hardware
acceleration for some 2D canvas content if WebKitGTK+ is built with
Cairo and its unstable CairoGL API.
Thes patch exposes both of these settings via vimb's settings engine.
Patrick Steinhardt [Sat, 20 May 2017 08:42:40 +0000 (10:42 +0200)]
hints: remove unused hints.js.h file
The "hints.js.h" file has been superseded by "scripts.h", which is
generated by make from our JavaScript and CSS files. As such, we can
remove the unused "hints.js.h" file and remove the include from
"hints.c".
Patrick Steinhardt [Sat, 20 May 2017 08:36:40 +0000 (10:36 +0200)]
setting: always clear scripts previous to adding global ones
Previous to adding user scripts to the content manager, we should always
clear existing scripts. Otherwise, e.g. in the sequence
:set user-scripts=off
:set user-scripts=on
we'd end up with the same global scripts injected twice.
Fix the issue by unconditionally clearing all user scripts previous to
adding scripts.
Daniel Carl [Fri, 19 May 2017 22:31:56 +0000 (00:31 +0200)]
Cast to OptArgFunction.
Daniel Carl [Fri, 19 May 2017 21:55:06 +0000 (23:55 +0200)]
Move include of hints.js.h to the right place.
Robert Timm [Fri, 19 May 2017 12:16:08 +0000 (14:16 +0200)]
adds insight about shortcut-default #365
Robert Timm [Fri, 19 May 2017 08:05:55 +0000 (10:05 +0200)]
adds incsearch to manpage (#365)
Daniel Carl [Thu, 18 May 2017 23:47:58 +0000 (01:47 +0200)]
Mention runsandbox target in README.
Daniel Carl [Thu, 18 May 2017 23:41:58 +0000 (01:41 +0200)]
Update change settings in CHANGELOG.
Daniel Carl [Thu, 18 May 2017 23:38:58 +0000 (01:38 +0200)]
Add settings for spell checking.
Daniel Carl [Thu, 18 May 2017 22:12:45 +0000 (00:12 +0200)]
Increase default z-index for hint elements.
There are some sites where the hint label where covered by on page
elements using a high z-index. So increase our default too.
Robert Timm [Thu, 18 May 2017 11:24:24 +0000 (13:24 +0200)]
fixes serif-font setting name to match manpage
Ferenc- [Thu, 18 May 2017 08:58:55 +0000 (10:58 +0200)]
Eliminate dead code from main.c
1. Value stored in 'num' in line 161 was never read
since it was unconditionally overwritten immediately in 166.
2. Value stored in 'suffix' in line 145 was never read
since it was overwritten in both branches of 'if(dot_post)'.
3. Value stored in 'req' in line 1157 was never read
if the branch of the first if statement is taken.
Storing has been placed int to the second if statement,
where it is actually used.
Daniel Carl [Tue, 16 May 2017 22:01:12 +0000 (00:01 +0200)]
Added missed ;x hinting to man page.
Daniel Carl [Tue, 16 May 2017 21:39:21 +0000 (23:39 +0200)]
Use dashed setting names.
The mixes use of none separated settings names and those containing
multiple dashes looked ugly. So use consequently dashes setting names.
Daniel Carl [Tue, 16 May 2017 21:23:33 +0000 (23:23 +0200)]
Added current available settings to man page #365.
Daniel Carl [Tue, 16 May 2017 21:21:48 +0000 (23:21 +0200)]
Added missed x-hint-command setting.
Daniel Carl [Mon, 15 May 2017 20:27:28 +0000 (22:27 +0200)]
Add space after sed -e option #388.
Daniel Carl [Fri, 12 May 2017 23:29:49 +0000 (01:29 +0200)]
Remove also whitespace around *%/[.
Daniel Carl [Fri, 12 May 2017 23:13:58 +0000 (01:13 +0200)]
Close comments in js on end of line.
The multi line comments /* */ must be closed on the same line. Because
the simple script that minifies the scripts a little can only remove
those on same line closed comments properly.
Robert Timm [Fri, 12 May 2017 21:32:15 +0000 (23:32 +0200)]
fixes :eval segfault (closes #397)
Michael Danilov [Thu, 27 Apr 2017 14:33:08 +0000 (16:33 +0200)]
js2sh.sh: sed for was GNU-specific.
Daniel Carl [Fri, 12 May 2017 11:26:39 +0000 (13:26 +0200)]
Mention mailing list also for the contributors.
Daniel Carl [Fri, 12 May 2017 11:16:19 +0000 (13:16 +0200)]
Moved contribution related stuff from README to CONTRIBUTE.
Daniel Carl [Thu, 11 May 2017 22:35:59 +0000 (00:35 +0200)]
Added editor to man page #347.
Daniel Carl [Thu, 11 May 2017 22:30:04 +0000 (00:30 +0200)]
Fixed wrong link identifier.
Daniel Carl [Thu, 11 May 2017 22:08:45 +0000 (00:08 +0200)]
Fixed wrong client to webpage relation #349.
In case a related webview is created. The relation between webextensions
web page and the client in the ui process where mismatched. In fact the
relation was correct, but when a dbus call was fired from ui to
webextension, the webextension used the last created web page to run
javascript in or to focus input fields.
This patch adds the page_id of the web page to the dbus calls that
target a specific web page. So that th webextension can get the right
page by this id to use to answer the call.
Also the communication from webextension to ui lagged this essential
information. So that a click to a editable filed in a related webview
all related instances into input mode switched.
Robert Timm [Thu, 11 May 2017 21:15:45 +0000 (23:15 +0200)]
implements external editor (closes #347)
Daniel Carl [Thu, 11 May 2017 12:55:32 +0000 (14:55 +0200)]
Removed dead code #393.
Daniel Carl [Thu, 11 May 2017 12:50:01 +0000 (14:50 +0200)]
Fixed possible null pointer dereference #392.
Daniel Carl [Thu, 11 May 2017 12:38:59 +0000 (14:38 +0200)]
Added inofficial arch linux pkgbuild.
Daniel Carl [Thu, 11 May 2017 12:35:45 +0000 (14:35 +0200)]
Updated README.
Also added known packages.
Daniel Carl [Thu, 11 May 2017 12:02:42 +0000 (14:02 +0200)]
Added hinting to man page.
Robert Timm [Tue, 9 May 2017 22:11:39 +0000 (00:11 +0200)]
fixes hintElem opacity for non opaque elements
Forces the hintElem to be fully opaque, even when attached to non opaque
elements (e.g. {opacity:0.5}). #349
Daniel Carl [Tue, 9 May 2017 18:59:52 +0000 (20:59 +0200)]
Don't give MFLAGS to make explicitly.
The option given to the upper most make call are already given as
MAKEFLAGS on recursive calls to make. So there is no need to give them
explicitly.
Virgil Dupras [Tue, 9 May 2017 00:10:35 +0000 (20:10 -0400)]
hints: open links in async mode
When firing hints, open them (either by simulating a click or through
`window.open()`) in async mode with `window.setTimeout()`. If we don't
do that, the `EvalJS` dbus call will itself timeout and we'll end up
in an inconsistent state, that is, not back to Normal mode.
ref #349
Daniel Carl [Sun, 7 May 2017 23:12:00 +0000 (01:12 +0200)]
Moved scrolling logic into javascript.
Daniel Carl [Sun, 7 May 2017 22:18:48 +0000 (00:18 +0200)]
Merge branch 'hints' into webkit2.
Daniel Carl [Sun, 7 May 2017 20:39:11 +0000 (22:39 +0200)]
Show scroll indicator in status bar #354.
Daniel Carl [Sun, 7 May 2017 20:39:59 +0000 (22:39 +0200)]
Fix wrong js to scroll to x percent of page.
Daniel Carl [Sun, 7 May 2017 12:47:44 +0000 (14:47 +0200)]
Use direct click method on element #349.
Previously there was some hacky target="_blank" setting unsetting logic
in the hints click method to force to open a hint into new instance or
the same. But this does not work and the hack was previously removed. So
there is no need to do the click event emulation by ourselves, it's
already available as method on the elements itself.
Daniel Carl [Sun, 7 May 2017 12:42:20 +0000 (14:42 +0200)]
Clear hints on entering normal mode #349.
Daniel Carl [Sun, 7 May 2017 12:41:51 +0000 (14:41 +0200)]
Workaround for hanging hints #349.
Daniel Carl [Sun, 7 May 2017 12:21:27 +0000 (14:21 +0200)]
Set hint css vie web content manager #349.
Add the hint css direct to webkit instead of manipulating the DOM to add
a style node. By the way the default style was removed from config.def.h
into src/scripts directory so that the css is minified during
compilation.
Daniel Carl [Sun, 7 May 2017 12:19:40 +0000 (14:19 +0200)]
Prefix minified content by file type.
Avoid naming collisions and prefix the minified scripts by JS_ so that
it's obvious what's their content.
Daniel Carl [Sun, 7 May 2017 11:44:05 +0000 (13:44 +0200)]
Inject global hints script during setting.
In case the user disabled user scripts, also the hints script was
removed from the web content manager. So if the page was reloaded the
hinting did not work. To avoid the disabling of vimb internal used
scripts, we set them always during set up of the settings. So they are
readded in case all scripts are removed from the web content manager.
Daniel Carl [Sun, 7 May 2017 00:03:19 +0000 (02:03 +0200)]
Run hint script syncron #349.
When we run the hinting asyn over dbus we can't use the return value
of the hinting to check if the action was done or not. So it was not
possible to undo last number filter on pressing backspace.
Daniel Carl [Sat, 6 May 2017 23:30:16 +0000 (01:30 +0200)]
Fixed missed quotes around filter value #349.
Daniel Carl [Sat, 6 May 2017 22:50:38 +0000 (00:50 +0200)]
Don't fail on same origin policy violations #349.
Daniel Carl [Sat, 6 May 2017 22:39:00 +0000 (00:39 +0200)]
Inject hinting script only in top frame #349.
We can not address sub frame scripts at the time and the hinting script
is able to process also frames, when this is allowed according to the
same origin policy. So there is no need to inject the script into
multiple frames.
Daniel Carl [Sat, 6 May 2017 22:34:51 +0000 (00:34 +0200)]
Allow to quit hint mode via <CTRL-C> #349.
There are some pages where the hinting could not be started and the
input box is filled with ';o'. If the user uses <Esc> this key is also
given to the hinting mode which can't handle this so the user has no way
to get back to normal mode.
Moved the <CTRL-C> case to the beginning of the key handler to make sure
the user can abort the current mode by <CTRL-C>.
Virgil Dupras [Fri, 5 May 2017 14:33:35 +0000 (10:33 -0400)]
Make the ";y" (yanking) hint command work
Virgil Dupras [Tue, 2 May 2017 00:34:53 +0000 (20:34 -0400)]
Make hints wotk in "new window" mode
The old "set target to _blank" trick doesn't work anymore since the
whole "noopener" vulnerability thing
(https://mathiasbynens.github.io/rel-noopener/)
I couldn't find a workaround. We're unfortunately now limited in the
kind of elements we can interact with in "new window" mode.
Virgil Dupras [Sat, 29 Apr 2017 02:24:37 +0000 (22:24 -0400)]
hints: re-enable hints function return value processing
Virgil Dupras [Sat, 29 Apr 2017 02:02:03 +0000 (22:02 -0400)]
hints: Re-enable nearly all call_hint_function invocations
Virgil Dupras [Thu, 27 Apr 2017 02:54:30 +0000 (22:54 -0400)]
Convert old hints.c to the webkit2 era
Lots of it is still disabled, but the basic hint showing happening when
pressing 'f' works.
Virgil Dupras [Mon, 24 Apr 2017 02:47:22 +0000 (22:47 -0400)]
Add hint display
Pressing 'F' will show hints with the old styling from the master
branch.
Virgil Dupras [Mon, 24 Apr 2017 00:53:34 +0000 (20:53 -0400)]
Very preliminary work for bringing hints back
Daniel Carl [Sat, 6 May 2017 21:36:46 +0000 (23:36 +0200)]
Merge branch '375_reject_window_manager_initiated_quit_if_downloads_are_running' of https://github.com/rti/vimb into webkit2
Daniel Carl [Sat, 6 May 2017 21:35:08 +0000 (23:35 +0200)]
Merge branch 'fix_typos' of https://github.com/rti/vimb into webkit2
Daniel Carl [Sat, 6 May 2017 21:32:39 +0000 (23:32 +0200)]
Merge branch '383_download_file_name_postfix' of https://github.com/rti/vimb into webkit2
Daniel Carl [Fri, 5 May 2017 23:55:27 +0000 (01:55 +0200)]
Don't set empty title is none is found.
In case a page without a title or a none html file which can be shown is
opened, webkit informed us about the title change to empty string. But
no window title is no good idea, especial in case vimb runs within
tabbed and there are multiple unnamed tabs.
So we set the webview title only if it's not empty.
Robert Timm [Sun, 23 Apr 2017 19:10:37 +0000 (21:10 +0200)]
Reject window manager quit if downloading
Rejects a window manager initiated quit signal if there are downloads in
progress. This closes #375.
Robert Timm [Thu, 4 May 2017 17:42:50 +0000 (19:42 +0200)]
fixes typos
Robert Timm [Thu, 4 May 2017 17:40:10 +0000 (19:40 +0200)]
fixes download file name postfix (closes #383)
Daniel Carl [Thu, 27 Apr 2017 21:22:33 +0000 (23:22 +0200)]
Changed default-zoom behaviour.
In the previous implementation the default-zoom was only a initial full
content zoom applied to the webview. But in case the user changed the
zooming and reset it back by using 'zz' the webkit zoom level was set to
1.0 (100%) and not to the initial zoom level like on startup of vimb.
This behaviour is strange to under stand and does not fit toe the
setting name 'default-zoom'.
To make the default-zoom to a real default, the zoom is also applied in
case the zoom is reseted by the user via 'zz'.
Daniel Carl [Thu, 27 Apr 2017 20:16:04 +0000 (22:16 +0200)]
Fix some typos.