Age | Commit message (Collapse) | Author |
|
The `SoupURI` interface has been deprecated in libsoup 3.0 in favor of
`GUri`, which is part of glib 2.66 and newer. Convert the codebase to
use the latter.
|
|
The JSValueRef interface has been deprecated in WebKit 2.22.0. Convert
the code to use the modern `JSCValue` interface instead.
|
|
|
|
Fixes #652
|
|
Do not store all files in XDG_CONFIG_HOME.
|
|
The % is often used in urls and in case of the x-hint-command those are
feed to :shellcmd and will be replaced by current URL. This made the
x-hint-command unusable on some search engines.
The expansion of % to the current URL also required to give the current
browser state to the expansion logic and to feed it to all callers of
this too. This bloated the code.
This patch removes the % expansion which was a redundant alternative to
$VIMB_URI.
|
|
Allow to clear different types of website data base on the last update
time.
|
|
If vimb is started with --ephemeral option no files are created by
default and no persistent cookie manager is used.
|
|
Thank to Valérian Rousset for pointing this out. Also change the
until_sanitize_uri function to return given uri in case an error occurred
during sanitization process to reduce cases where this function returns
NULL.
|
|
|
|
|
|
Use this function for shown url for IDN homograph mitigation.
|
|
|
|
|
|
|
|
Single ~ uses g_get_home_dir() that honor HOME environment variable.
However, ~user always consult the passwd file.
|
|
|
|
Remove the mode arguments from util_file_prepend_line(),
util_file_pop_line() and util_file_set_content().
Both util_file_prepend_line() and util_file_pop_line() just calls
util_file_set_content() so stat(2) can be used there and if it
fails the 0600 is used as a fallback.
Thanks to @fanglingsu for reviews and suggestions!
|
|
The g_file_set_contents performs atomic write to file by creating a
temporary file, writing to it and renaming it. But during the creation
of the temporary file, the mode is set hard to 0666. So our files will
silently always change their mode in case we processed their content.
This patch adds the util_file_set_content() function which follows the
same approach, but allows to set the mode that is used to create the
temporary file. So the file is created with the right permissions.
|
|
Add a mode argument to util_get_filepath() in order to adjust file
permissions when creating file. Adjust all util_get_filepath()
call and file permissions making them readable and writable only
by the user.
|
|
This fixes #492.
|
|
Give only those information the util functions need to work.
|
|
|
|
Most of the time uri do not contain credentials, so don't run expensive
uri cleanup if there is not @ char in uri indicating that this might
contain at least a username and possibly also and password.
|
|
This will allow us to used this in other parts too.
|
|
|
|
|
|
|
|
|
|
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Use script message handler instead of dbus to track for focused editable
elements to switch vimb into input mode or back to normal mode.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
New parameter is introduced to allow multiple configuration profiles per
user.
If vimb is started with this parameter new configuration directory
is created under default configuration directory. Cache and socket file
are kept separate per profile as well.
If vimb is started without this parameter, behaviour is unchanged.
Resolves fanglingsu/vimb#129
|
|
|
|
This makes it easier to maintain the code and to avoid memory leaks.
|
|
The changes in the way the memory is allocated, cause a memory leak because
all those history items that where read from file but where not put into the
list, could not be freed by the caller.
|
|
The previous duplication check where don on the generated list of history
items with callback function which is really slow for large history files. Now
the histories url is put into a hash table for a faster duplicate check.
Additional to this some unneeded memory allocation where removed. This makes
the code a little harder to maintain, but hey we don't want to wast time and
memory here.
|