-
kurion
lovetox: I guess, I can work with `Gtk.ListBox.signals.row_selected`
-
kurion
For now, I have
-
kurion
```✎ -
kurion
``` def _on_msgrow_selected(self, listbox, row) -> None: print('selected row no. ' + str(self._list_box.get_selected_row().get_index()) + ' of ' + str(self._contact.jid.localpart)) ``` ✏
-
kurion
got hold of the variables I need to work with.
-
aquatarkus
hi, how can I send attachments with the gajim flatpak?
-
aquatarkus
clicking on "add files" does nothing
-
aquatarkus
console says: `Can't open portal file chooser: GDBus.Error:org.freedesktop.DBus.Error.UnknownMethod: No such interface “org.freedesktop.portal.FileChooser” on object at path /org/freedesktop/portal/desktop`
-
aquatarkus
I went to flatseal and allowed gajim access to the session bus, still it will not work
-
lovetox
Google the error
-
lovetox
It's nothing Gajim can influence
-
aquatarkus
I did, so is the wlr desktop portal just broken with flatpaks? I only installed gajim as a flatpak because the normal arch package is broken / doesn't work
-
aquatarkus
``` https://conference.gajim.org:5281/pastebin/d7ff94e2-53c8-40ad-89c6-2922935b4e1d
-
aquatarkus
^ this is the error from the normal arch package
-
lovetox
hm did you migrate to a new gajim version ?
-
lovetox
this error basically says your account is invalid setup
-
lovetox
this can be solved by removing the config
-
lovetox
.config/gajim
-
lovetox
but of course this will lose all your settings
-
kurion
If I make a `dict` in `view.py` to store index of last selected `MessageRow` for each chat, in which file should I implement the shortcut to focus on that index?
-
kurion
the `dict` in `ConversationView` should be accessible from that file in a good way.
-
kurion
I've thought about making the shortcut in `main.py`.
-
kurion
the way I would access ConversationView from `main.py` would be
-
kurion
```✎ -
kurion
``` def _focus_last_visited_message(self, _action: Gio.SimpleAction, param: None) -> None: chat_stack = self._chat_page.get_chat_stack() view = chat_stack._chat_control._scrolled_view dict = view.last_visited ``` ✏
-
kurion
But this does not look okay.✎ -
kurion
Obviously, this does not look okay. ✏
-
aquatarkus
lovetox: alright I'll try this. Yes, I have been switching around from the git version to the normal arch package and back
-
aquatarkus
gajim launched successfully after removing settings.sqlite
-
kurion
I need to have that shortcut available as "win.focus-last-visited-message" in `shortcuts.json`. That is why I implemented the method in `main.py`.
-
lovetox
kurion, the idea of actions is
-
lovetox
that you register a action for a window or app
-
lovetox
then you can connect to that action from anywhere in the code
-
lovetox
and register a callback
-
lovetox
check for example _connect_actions in chat_stack.py
-
lovetox
the actions are registered somewhere else, but the code that needs the info when this action is triggered should connect to it
-
lovetox
so i guess you want the conversatonview to know when this action is triggert
-
lovetox
so it should connect to that action and register a callback
-
lovetox
except you want that the action also switches chat
-
lovetox
then of course it needs to be higher in the hirachy
-
kurion
The UX I have in mind is, I switch chats with `Ctrl+Tab` and press `Ctrl+L` and that lands focus on the last selected `MessageRow` for that chat.
-
kurion
I am checking out `_connect_actions` in `chat_stack.py`
-
aquatarkus
hi, are the contacts nicknames in Gajim shared with the server?
-
☭Mike Yellow
The contacts nicknames are shared with the server no matter what the client is.
-
aquatarkus
thank you
-
aquatarkus
would be nice for there to be an option to keep it locally for privacy
-
lovetox
aquatarkus, not sure what you mean
-
aquatarkus
what I mean by what? by contact nicknames, or by keeping it locally only?
-
☭Mike Yellow
> would be nice for there to be an option to keep it locally for privacy Well... You can remember every address you want to contact without adding them into your roster.
-
☭Mike Yellow
lovetox, They is too concerned about their privacy.
-
☭Mike Yellow
Gajim can contact someone without adding them into your roster.
-
aquatarkus
I know, I'm not complaining or anything
-
aquatarkus
I just said that it would be neat if Gajim could use an offline contacts list instead, or at least for the nicknames to be kept locally and not uploaded to the server
-
☭Mike Yellow
>Well... You can remember every address you want to contact without adding them into your roster. Some servers and somebody will block strangers that are not in their roster.
-
☭Mike Yellow
aquatarkus, If users want the server to block someone, the server MUST know the address.
-
aquatarkus
I'm not talking about the address, but rather about the nickname
-
lovetox
in what scenario ? when you join a groupchat?
-
lovetox
because otherwise your nickname is only shared with people you want it to share
-
aquatarkus
let's say I have this one friend, and we want to communicate privately while not leaking much metadata. We use gibberish addresses and communicate over Tor. But for the sake of simplicity, I added their real name as their nickname on my contacts list.
-
aquatarkus
because I expected that to be clientside
-
lovetox
it is clientside, why do you think its not?
-
aquatarkus
Mike said above that it's uploaded to the server
-
aquatarkus
is it not? good then
-
☭Mike Yellow
aquatarkus, Gajim is open-source, you can change it to whatever you like.
-
aquatarkus
I know, I'm not complaining...
-
lovetox
aquatarkus, ok sorry, yes if you set a nickname in your roster
-
lovetox
this is sent to the server, because the roster and all its information are stored there
-
aquatarkus
alright, ty
-
kobraa
тут
-
qy
Tyttö
-
fjklp
does anyone have any ideas on how to reproduce the "getting kicked from muc" condition that results in the message from the server "Error: You are not currently connected to this chat"?
-
fjklp
my guess is it might have been caused by an out of memory condition on the account server but I don't really understand this situation
-
mjk
couldn't muc server restart cause this?
-
kurion
what is a quick way to select the last ListboxRow of a Listbox?
-
kurion
It seems like a single specific method does not exist for this.✎ -
kurion
It looks like single specific method does not exist for this. ✏
-
lovetox
There is a get by index method
-
lovetox
And maybe combine this with a count method or something like that
-
lovetox
But if I remember we already count the rows somewhere
-
kurion
yup, I guess I found it.
-
kurion
`row_count = len(self._list_box.get_children())` in ConversationView
-
lovetox
And index may start with 0
-
kurion
Thanks. I found `get_last_message_row` method in ConversationView.
-
kurion
did the job.✎ -
kurion
that did the job. ✏
-
Mx2
hi, flatpak nightly still not works..?