Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wayland colorpicking #619

Draft
wants to merge 19 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@ jobs:
../configure --prefix /usr
make
make install
- name: libportal-4.0 from source
run: |
git cline https://github.com/flatpak/libportal/
madjesc marked this conversation as resolved.
Show resolved Hide resolved
cd libportal
git checkout f68764e
meson build
ninja install
- name: Build
# env:
# DESTDIR: out
Expand Down
12 changes: 11 additions & 1 deletion build-aux/flatpak/com.github.akiraux.akira.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,17 @@
"--filesystem=xdg-run/gvfs",
"--filesystem=xdg-run/gvfsd"
],
"modules": [{
"modules": [
{
"name": "libportal",
"buildsystem": "meson",
"sources": [{
"type": "git",
"url": "https://github.com/flatpak/libportal.git",
"tag": "0.4"
}]
},
{
"name": "goocanvas",
"config-opts": ["--enable-python=no"],
"build-options": {
Expand Down
1 change: 1 addition & 0 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ cairo_dependency = dependency('cairo', version: '>=1.14')
goocanvas_dependency = dependency('goocanvas-3.0')
libarchive_dependency = dependency('libarchive')
json_glib_dependency = dependency('json-glib-1.0')
libportal_dependency = dependency('libportal')

# Optional dependencies
desktop_file_validate = find_program('desktop-file-validate', required: false)
Expand Down
15 changes: 0 additions & 15 deletions src/Services/ActionManager.vala
Original file line number Diff line number Diff line change
Expand Up @@ -470,19 +470,6 @@ public class Akira.Services.ActionManager : Object {

bool is_holding_shift = false;
var color_picker = new Akira.Utils.ColorPicker ();
color_picker.show_all ();

color_picker.key_pressed.connect (e => {
is_holding_shift = e.keyval == Gdk.Key.Shift_L;
});

color_picker.key_released.connect (e => {
is_holding_shift = e.keyval == Gdk.Key.Shift_L;
});

color_picker.cancelled.connect (() => {
color_picker.close ();
});

color_picker.picked.connect (color => {
foreach (var item in canvas.selected_bound_manager.selected_items) {
Expand All @@ -500,8 +487,6 @@ public class Akira.Services.ActionManager : Object {
item.fills.update_color_from_action (color);
}

color_picker.close ();

// Force a UI reload of the fills and borders panel since some items
// had their properties changed.
canvas.window.event_bus.selected_items_list_changed (canvas.selected_bound_manager.selected_items);
Expand Down
Loading