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

mac: unclear window dragging areas #4018

Open
r10s opened this issue Jul 9, 2024 · 5 comments
Open

mac: unclear window dragging areas #4018

r10s opened this issue Jul 9, 2024 · 5 comments
Labels
bug Something isn't working OS: Mac Related to MacOS

Comments

@r10s
Copy link
Member

r10s commented Jul 9, 2024

mac got an "integrated titlebar", which looks great.

however, there are some bugs.

  • in enlarge image view (and maybe other views covering the main screen), the dragging areas are the ones from the underlying chat. this results in mostly random behaviour, when the user tries to drag the window - either the window is dragged, the image is dragged or nothing happens. see video#1 below

  • in "add account", the window cannot be dragged at all. we sorted that as a "bug that should not hold the release" that time, but meanwhile it is time to get a grip on that :) (not sure if there is another issue)

  • in the normal chatview, the width of the "profile open area" is the max. of title/subtitle. this leads to confusion esp. when the subtitle is longer - some parts close to the window margin drag the window, others do not. it seems better to make "profile open area" fit to the text, see video#2 below

Screen.Recording.2024-07-09.at.13.51.29.mov
Screen.Recording.2024-07-09.at.13.57.48.mov
@r10s r10s added the bug Something isn't working label Jul 9, 2024
@Simon-Laux
Copy link
Member

Simon-Laux commented Jul 9, 2024

another issue in this category is #3804, it has some explanations about how the drag regions work.
The problem with them is that they are not always easy to understand, see the "enlarge image view" aspect. (there is another element in front, but the drag region is still defiled by the navbar that is in the background)

@Simon-Laux Simon-Laux added the OS: Mac Related to MacOS label Jul 9, 2024
@Simon-Laux
Copy link
Member

I guess we could should give "-webkit-app-region: no-drag; and -webkit-app-region: drag; "css" properties," a try again, maybe make all dialogs and the context menu "-webkit-app-region: no-drag"/ (css class .no-drag) by default

@Simon-Laux
Copy link
Member

Also related #3926. I think all these issues can be fixed in one go.

@cobber
Copy link

cobber commented Aug 12, 2024

bump!

I got stuck with this today...
deltachat opened on the wrong display and it took me multiple attempts incl. re-starting deltachat before I found an invisible pixel that let me drag the window.

I don't mind having title bars on windows.
Sure, losing them saves pixels etc, but compared to the pixels lost via #3970 and the non-adjustable contacts list, having a proper titlebar is only a fraction of the real-estate.

If that's too old Skool, ok, but if the title bar is going to be overloaded with widgets as it is now, then I would expect that dragging things which can't be dragged (e.g. the buttons on the right or the background behind the close/minimize/maximize buttons) should drag the whole window.

@Simon-Laux
Copy link
Member

then I would expect that dragging things which can't be dragged

when using electrons api for that then the area you apply it to is not interactive anymore.
Maybe it's possible to emulate dragging in javascript and then calling electron to move the window, but I think thats too hacky.

I'd say we should try to fix drag areas fist and if that doesn't work then redesign it so that it does.

Simon-Laux added a commit that referenced this issue Aug 29, 2024
Simon-Laux added a commit that referenced this issue Aug 29, 2024
* set min height for shared chats in profile view
fixes #4092

* more clear varname

* refactor styles a tiny bit to make status text scroll if there is little space

* remove workaround from #4068, can't reproduce the bug of it anymore

* fix that you can not click header button in dialog when they are on top of the navbar
also see #4018

* add changelog entries
Simon-Laux added a commit that referenced this issue Aug 29, 2024
* set min height for shared chats in profile view
fixes #4092

* more clear varname

* refactor styles a tiny bit to make status text scroll if there is little space

* remove workaround from #4068, can't reproduce the bug of it anymore

* fix that you can not click header button in dialog when they are on top of the navbar
also see #4018

* add changelog entries
Simon-Laux added a commit that referenced this issue Sep 8, 2024
* set min height for shared chats in profile view
fixes #4092

* more clear varname

* refactor styles a tiny bit to make status text scroll if there is little space

* remove workaround from #4068, can't reproduce the bug of it anymore

* fix that you can not click header button in dialog when they are on top of the navbar
also see #4018

* add changelog entries
Simon-Laux added a commit that referenced this issue Sep 9, 2024
* set min height for shared chats in profile view
fixes #4092

* more clear varname

* refactor styles a tiny bit to make status text scroll if there is little space

* remove workaround from #4068, can't reproduce the bug of it anymore

* fix that you can not click header button in dialog when they are on top of the navbar
also see #4018

* add changelog entries
Simon-Laux added a commit that referenced this issue Sep 9, 2024
* - convert project to use pnpm instead of npm
- docs: mark e2e testing section as "defect"
- remove vscode lint task

* remove unused file

* remove testcafe stuff

* move bulk of source files, does not work yet

* more progress like adjusting paths, making new packages and updating docs

* ts: change all targets to es2018

* set min pnpm and nodejs versions in package.json

* add check:types script

* use pnpm workspace catalogs for shared dependencies

* add scripts to change the core thats used

* fix fmt

* script to update/sync versions for targets

* replace remaining references to electron from runtime interface:
- `Electron.OpenDialogOptions` -> `RuntimeOpenDialogOptions`
- qelectron.app.getPath()` -> `RuntimeAppPath`

* fix lint of shared import in frontend

* disable drag and drop files for now

It is easier to fix later when we can test it

* on paste: remove usage of `File.path` which was not set in some of the cases.

* add missing debounce dependency to target-electron

* fix lint of shared import in target-electron

* global definition for electron-runtime

* fix fmt

* remove last direct usage of electron from frontend.
move Deltachat jsonrpc transport to runtime-interface implementation

* bundle backend code (targe-electron),
move most dependencies to dev dependencies because they are now bundled

* proper native sourcemap support during development for main process

* mention `NODE_OPTIONS=--enable-source-maps` in docs

* document `TEST_DIR`

* fix loading locales in electron main process for devleopment
Also add `DELTACHAT_LOCALE_DIR`env var to allow replacement of the localse folder. useful for debuging but you could also make a tool for users to live edit translations in a released version of deltachat together with the `--translation-watch` flag.

* fix fmt

* add the idea for end user translation tool to docs in a footnote

* make build info part of the runtime
and its generation part of the target-electron build script

* rm used yerpc import in backend-com

* move non shared types from shared to where they belong.
Also improved some comments.

* sort scripts by whether they work yet

* progress on making frontend build (ts and scss so far)

* fix path in comment

* - sort static files into to their projects
- new location for themes html-dist
- make build themes script a bit faster and simpler

* make copy fail with exit code 1 if dir is not found (unless it is started in watch mode)

* make it run again (styles are broken but basics and logic work)

* reintroduce dev script as alias to dev:electron

to make transition easier for devs

* fix blueprint import (bundle it)

* fix images and icons

* fix loading themes

* update theming docs

* remove dead code

* use correct log level when logging to console in main process

* make drag and drop work again

this could have fixed the following issue #3595 as a side effect, if not then that issue is not fixable, altleast unless we start interacting with the OS Apis directly in a native module or by contributing to electron.

* harden electron functions, only runtime can use them now

* harden runtime by deleting the reference on window (`window.r`) after the first use.
For development it is now accessible at `exp.runtime` but only in --devmode like `exp.rpc`

* update_core docs:  update the start command for electron

* fix eslint issues and fix formatting

* improve ./bin/test_for_missing_translations.sh script

it's now more correct, helpful and faster

* update ./bin/topEvil.sh script

* scripts to update and check package versions

* update prettierignore

* update ./bin/update_background_thumbnails.sh script

* fmt language list

* update theme builder script to use compileString instead of renderSync, because the latter is deprecated

* fix that composer was monospace font

* tests for packages/shared

* make migration test work

* add testing to ci

* add test-and-check script

* make watch scripts work

* docs: add hint about completion in terminal for pnpm

* make packaging work again

* update ci and docs

* make `check:log-conventions` part of checks

* update dev docs

* update more pnpm commands

* delete old package.json

* update file tree in docs

* ci: fix building preview

* update the versions (for/from main branch rebase)

* add changelog

* runtime: also use catalog: dependency on @deltachat/jsonrpc-client

to fix tests

* test building in ci and fix ci test

* ci: fix dev-builds

* add comment to `previewBuild` variable in gen-electron-builder-config.js

* update target versions

* fix preview build ci

* fix devbuild

* fix tray and app icon

* other appid for preview build on mac

* fix readme commands

* Fix if Contact has long bio, then shared chats are hidden (#4093)

* set min height for shared chats in profile view
fixes #4092

* more clear varname

* refactor styles a tiny bit to make status text scroll if there is little space

* remove workaround from #4068, can't reproduce the bug of it anymore

* fix that you can not click header button in dialog when they are on top of the navbar
also see #4018

* add changelog entries

* fix fmt

* update versions after rebase to match main branch:
- deltachat-core (stdio-server and jsonrpc-client) 1.142.10
- electron-notarize 2.4

* fix chatlist image thumbnails (#4101)

* fix chatlist image thumbnails

* changelog entry

* update core after rebase

* fix changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working OS: Mac Related to MacOS
Projects
None yet
Development

No branches or pull requests

3 participants