Commit graph

1092 commits

Author SHA1 Message Date
Christopher Davis
336f0b22ae ui: Separate login from main_window.ui
Branches the login flow off from the main window's UI file.
Like the account settings view we can add it to the stack
manually at run-time. This cuts down greatly on the
complexity of the main_window file.
2019-04-15 10:30:58 -04:00
Alexandre Franke
7eec414e3c rust: fix some warnings 2019-04-14 18:07:26 +02:00
Jiri Grönroos
0e08877ef4 Update Finnish translation 2019-04-14 12:36:33 +00:00
Kukuh Syafaat
67eaee9609 Add Indonesian translation 2019-04-12 10:31:35 +00:00
Symphorien Gibol
c0de295a2c AppOp::set_active_room_by_id: call set_state after changing the active room
Fixes GNOME/fractal#470
2019-04-10 06:47:46 +00:00
Rafael Fontenelle
5c4afada48 Update Brazilian Portuguese translation 2019-04-05 12:38:50 +00:00
Zander Brown
cd750dec44
Only add margin to the start of message rows
Allows text to flow right to the edge, important on smaller devices

Also avoids use of child properties which are going away soon
2019-04-03 21:50:30 +01:00
Christopher Davis
d0887529fa media_viewer: Remove zoom controls
Until we get a proper image viewer widget, we've
decided that it's best to remove the zoom controls
instead of having broken ones.
2019-04-02 07:43:04 +00:00
Piotr Drąg
f39555bbc4 Update Polish translation 2019-03-25 12:55:41 +01:00
Crom (Thibaut CHARLES)
d60ce58cf3
power_level badges for users in room settings
Used Avatar::circle badge parameter in MemberBox

rustfmt

Show power level next to the matrix user ID

Fix mxid & power level forcing window width

new design closer to @bertob's proposal

Gap around avatar's badge

Power level roles translation

css-themed avatar's colored dot

Reduced badge height
2019-03-18 20:46:12 +01:00
Balázs Meskó
ef8f3c8e58 Update Hungarian translation 2019-03-16 17:21:33 +00:00
Piotr Drąg
6ae32b5aa2 Update Polish translation 2019-03-16 11:34:35 +01:00
Christopher Davis
79f02009d5 Minor style changes to typing notifications
* In typing notifications with 2 people, bold both names
* Match the size of emotes
2019-03-15 11:08:14 +00:00
Daniel García Moreno
d62bcc2cbd Replace tabs with spaces in app macro 2019-03-15 10:50:49 +00:00
Xiang Fan
bdb4d5c7af account: Make stack non-homogeneous
The spinner should be at the center of the view, not the other child of
the stack.
2019-03-15 15:53:19 +08:00
Xiang Fan
5ea9b0c6a3 account: Fix foci
Some labels have focus and some buttons don't. This should fix it.
2019-03-15 15:52:31 +08:00
Christopher Davis
908a837b78 room_history: re-enable kinetic scrolling after loading more
Previously kinetic scrolling was disabled while loading more
messages and was never re-enabled. This could lead to rooms
not scrolling with touch gestures.

Now after we add widgets to the top, we re-enable kinetic
scrolling for our ScrolledWindow.

Fixes https://gitlab.gnome.org/GNOME/fractal/issues/458
2019-03-14 13:46:29 +00:00
Anders Jonsson
2421ac1bd7 Update Swedish translation 2019-03-13 09:59:27 +00:00
Daniel García Moreno
54a1144ea8 Merge branch 'merge-requests/387'
account_settings: Remove revealer boxes

https://gitlab.gnome.org/GNOME/fractal/merge_requests/387
2019-03-13 10:40:57 +01:00
Xiang Fan
04aca0129c account: Downgrade scroll for callbacks 2019-03-13 09:00:46 +00:00
Xiang Fan
330bca114b account: Reduce unwanted scrolling
"size-allocate" signal can be triggered even when the revealer's state
doesn't change, so we need to check if the revealer is actually
revealing.

The 'obvious' solutions for this don't work. If we connect to
"child-revealed", the scroll only happens *after* expanding the
revealer. If we connect to "reveal-child", we'll only scroll to the
bottom at the beginning of the revealer's expansion, so the list will
grow longer without scrolling.

The handling is still imperfect though, since we always scroll to bottom
regardless where the revealer is.
2019-03-13 09:00:46 +00:00
Christopher Davis
a3654a6ae1 fractal-gtk: Clean up some mistakes with loggerv
When allowing stable builds to test verbosity, there
were a few mistakes that caused the stable build to fail.
This commit cleans up those mistakes and makes sure
we don't have an unused variable that produced a warning
for stable builds.
2019-03-10 05:13:52 +00:00
Rafael Fontenelle
4637c042a3 Update Brazilian Portuguese translation 2019-03-09 21:34:24 +00:00
Daniel Mustieles
1327faef17 Update Spanish translation 2019-03-08 11:46:41 +00:00
Nathan Follens
f52f26449d Add Dutch translation 2019-03-08 10:14:08 +00:00
Christopher Davis
8995697f54 fractal-gtk: Use clap to set verbosity for release builds
By default, a release build of Fractal will only log errors.
A debug build will use the max level for development
purposes.

Running `fractal -v` will get users the same verbosity as
the debug build. Subsequent `-v`s will use increased
verbosity that will include extra info from our dependencies.
2019-03-07 20:59:51 +00:00
Christopher Davis
8f8a2d0a94 fractal-gtk: Use loggerv for log output
Previously we moved from println! to the `log` crate, but `log` requires you to set a logger in order to output anything. `loggerv` is one such logger, with detailed output that tells you exactly where a log comes from.

Closes https://gitlab.gnome.org/GNOME/fractal/issues/430
2019-03-07 20:59:51 +00:00
Piotr Drąg
a91a1a1681 Update Polish translation 2019-03-07 11:59:15 +01:00
Rasmus Rendal
48c8013be4 Add typing notifications
Add handler for incoming typing notifications in the sync loop
Add an appop handler for typing notifications to the frontend

Feature added for #305
2019-03-07 08:40:03 +00:00
Xiang Fan
b2135efac2 account_settings: Remove revealer boxes 2019-03-04 09:53:47 +00:00
Xiang Fan
9e92d3e1ab room_history: Add missing day divider between existing and old messages 2019-02-27 10:04:13 +00:00
Daniel Mustieles
ecbf32d489 Updated Spanish translation 2019-02-26 09:17:39 +01:00
mairandomness
e795177d27 create get_file_media_info 2019-02-25 14:41:41 -05:00
Piotr Drąg
2fa9b3f32b Update Polish translation 2019-02-25 13:49:59 +01:00
Robert Griesel
b4b38868ad Save and restore window state
Size, position and window maximize state are saved in gsettings
when closing Fractal. They are then restored on startup.

Window position is not working on all windowing systems.

Fixes #123
2019-02-25 11:01:33 +00:00
Xiang Fan
d7d7ae3004 cache: Fix reinitializing cache after destroying it
Currently the cache's directory is only initialized at first access. If
the cache gets destroyed the directory won't be created again, so future
cache data in the process cannot be saved. This can be reproduced by
logging in immediately after logout.
2019-02-25 07:54:14 +00:00
Xiang Fan
bba93fc3ea account: Fix minor typo 2019-02-24 21:37:50 +08:00
mairandomness
d71da4afec change thumb path to random file name in temp 2019-02-24 07:58:57 -05:00
mairandomness
a384c19472 create upload_thumbnail
change get_image_media_info to include thumbnail

propagate need for backend

try to debug the code

remove a println I forgot

Progress on using channel for thumb uploads

move thumbnail code to the backend

fix mimetype on json and only call ge_image_media_info on image files

remove random 'e' from util.rs

move get_image_media_info back to the frontend

create Info struct

hehe

lol
2019-02-24 07:58:57 -05:00
Mario Blättermann
25c369655f Update German translation 2019-02-22 21:49:34 +00:00
mairandomness
e8bb1c71e2 add proper type categorization on audio file upload
add duration to

remove unwraps and put early return in place

change branch in flatpak file to master for our master branch

add gstreamer-editing-services dependency

trade match statements for the ? operator

start video upload support

match mime types from the matrix-sdk library

delete meee
2019-02-21 20:59:01 -05:00
Yuri Myasoedov
6375f530eb Add Russian translation 2019-02-20 18:36:14 +00:00
Julian Sparber
6aa7230cdf use gspell from crates 2019-02-18 09:25:44 +00:00
Balázs Meskó
9446b2d716 Add Hungarian translation
(cherry picked from commit aedbeb241e)
2019-02-17 23:44:21 +00:00
Artem Polishchuk
5753d37582 Add Ukrainian translation 2019-02-16 14:32:12 +00:00
Christopher Davis
345c267d9f fractal-gtk: Use HdyDialog for Dialogs
HdyDialog is an adaptive version of GtkDialog that's always modal and adapts to fit the size of the screen if folded with HdyLeaflet. In the process of changing to use HdyDialog the width_request of the dialogs was moved from the window to their HeaderBars.

Related to https://gitlab.gnome.org/GNOME/fractal/issues/377
2019-02-15 12:03:11 -05:00
Alejandro Domínguez
dc924b1be0 API: Implement and use user request and response types 2019-02-15 13:19:52 +00:00
Christopher Davis
4d601d6472 dependencies: Remove tree_magic from fractal-gtk
Fractal crashes when switching to rooms with images due
to an issue with tree_magic. We used tree_magic to sniff out
the mime type, but we can use gio::FileInfo instead.

Related to https://gitlab.gnome.org/GNOME/fractal/issues/37
2019-02-14 16:51:27 -05:00
Jiri Grönroos
1f6cb8b676 Update Finnish translation 2019-02-10 17:59:43 +00:00
Christopher Davis
5f5903ad46 room_settings: Wrap settings in HdyColumn
Allows for the room settings to fit within small sizes.

Related to https://gitlab.gnome.org/GNOME/fractal/issues/377
2019-02-06 18:22:04 +00:00
Christopher Davis
ca3dd2d3b0 widgets/message.rs: Implement hold to right click
Right click is not possible on touchscreens, so our right click menu would be inaccessible.

Here we use GtkGestureLongPress to create our right click menu, but only on touch devices.
2019-02-06 11:00:11 +00:00
Marek Cernocky
260b8de1e7 Updated Czech translation 2019-02-06 09:28:02 +01:00
Christopher Davis
6d99cd8593 main_window: set width-request for content
The width-request of the HeaderBar dictates what size the room HeaderBar needs to be to fold at and the minimum width of the HdyLeaflets total in this case.

Prevents the room content from becoming too narrow.
2019-02-01 08:54:43 -05:00
Christopher Davis
36c1d827b3 main_window: wrap room_info GtkBox in GtkScrolledWindow
The room_info labels could cause the leaflet to fold before
they could ellipsize, causing Fractal to fold at the wrong width. By wrapping in ScrolledWindow we work around that issue.
2019-02-01 08:54:43 -05:00
Christopher Davis
3b69e8e898 fractal-gtk: Use HdyLeaflet to adapt to small sizes
Fractal's main view could only shrink so far, barring usage at smaller sizes such as a phone's screen. HdyLeaflet enables
Fractal to adapt.

Related to https://gitlab.gnome.org/GNOME/fractal/issues/377
2019-02-01 08:54:43 -05:00
Christopher Davis
0b8055dff8 appop: Remove RoomPanel enum and room_panel() func
The functionality from these symbols have been moved into
set_state().
2019-02-01 08:54:43 -05:00
Julian Sparber
9cdf4760cd room: download full list of members for each room 2019-02-01 08:46:03 +00:00
Julian Sparber
c40553c9d3 avatar: download, cache and remove room avatar 2019-02-01 08:46:03 +00:00
Julian Sparber
9b1756575b backend: clean up room avatar request
We used to request the complete room state to get only the memebers list
if there was no avatar, which was expensive and we actually have already
the members list.
This reduces memory use.
2019-02-01 08:46:03 +00:00
Christopher Davis
8537c5edc1 Revert "fractal-gtk: Use git version of tree_magic"
This reverts commit dac4e17e28.
The commit traded an inconsistent crash with a consistent freeze.
2019-01-31 16:19:24 -05:00
Christopher Davis
279d334010 markdown_popover: Remove deprecated props and clean up
`markdown_popover` used the deprecated start and end properties and abused margins to space elements out.
Now it uses the `margin` property to create margins around widgets on all sides, as well as the properties of GtkGrid and GtkBox.
2019-01-30 17:48:09 +00:00
Christopher Davis
dac4e17e28 fractal-gtk: Use git version of tree_magic
tree_magic did not previously return an Option from `from_filepath`, and used `unwrap()` internally, occasionally causing a crash when we used `is_gif()`.

On git master they have fixed this, so that's what we need to use until they put out a new release.

Related to https://gitlab.gnome.org/GNOME/fractal/issues/37
2019-01-30 00:31:10 -05:00
Daniel Mustieles
2704435800 Update Spanish translation 2019-01-29 15:51:16 +00:00
Daniel Mustieles
d2051858b9 Update Spanish translation 2019-01-28 14:19:25 +00:00
Rafael Fontenelle
71fa56f18c Update Brazilian Portuguese translation 2019-01-23 16:09:09 +00:00
Alejandro Domínguez
58c86df864 Add types related to third party protocol module API 2019-01-22 20:19:24 +01:00
azdle
2f3401f67a hookup the mouse back button to the 'app.back' action 2019-01-22 16:48:54 +00:00
Julian Sparber
6f643c12c7 backend: add a RoomMembership to Room type
This replaces some boolean properties of the Room Model with a single
property called membership. This makes the room membership (joined, left,
invited) and tag (favourties, low priority, etc) mutch more
understandable and gives the Model a better structure.
2019-01-22 17:24:32 +01:00
Daniel García Moreno
efd64a7c07 Ellipsize long display names in member list
Fix #428
2019-01-21 11:51:26 +01:00
Julian Sparber
9b6f53786f backend: force id on every Message
Since every message has to have a ID, this drops the Option for id in
the Message Model
2019-01-20 18:15:47 +00:00
Anders Jonsson
d2d1872b42 Update Swedish translation 2019-01-20 16:58:08 +00:00
Carmen Bianca BAKKER
60991cd300 Add Esperanto translation 2019-01-20 11:50:03 +00:00
Julian Sparber
aafd8096c5 sidebar: fix notification counter style 2019-01-19 11:23:43 +01:00
Piotr Drąg
58fec8d6b5 Update Polish translation 2019-01-17 11:26:12 +01:00
Piotr Drąg
182cfd9bb7 Use Unicode apostrophes in new user-visible strings
See https://developer.gnome.org/hig/stable/typography.html
2019-01-16 19:02:33 +01:00
Piotr Drąg
2c7fcb5e95 Update POTFILES.in 2019-01-16 19:00:32 +01:00
Jiri Grönroos
f77758f1e0 Update Finnish translation 2019-01-16 17:53:00 +00:00
Julian Sparber
b088a0da0c file_chooser: add file filter 2019-01-16 11:47:47 +00:00
Julian Sparber
cf68e36c75 use Gaction to change avatar in room/account settings 2019-01-16 11:47:47 +00:00
Piotr Drąg
319136b66f Update Polish translation 2019-01-15 20:07:08 +00:00
Christopher Davis
b17fe29c56 sourceview_entry: Clean up self imports
We previously included `self` of different crates so we could get things from the crates' roots with crate_name::ObjectName; This can be done in Rust 2018 without
the explicit self.
2019-01-15 10:43:07 -05:00
Christopher Davis
6982765607 fractal-gtk: Use gspell for spellchecking
With the move to GtkSourceView, we no longer had spellcheck
support in Fractal as bindings for GspellTextView were not generated.

Related to https://gitlab.gnome.org/GNOME/fractal/issues/124
2019-01-15 10:33:57 -05:00
Elizaryev Pavel
2d7c906c0a media_viewer_menu.ui: replace "..." with "…" 2019-01-15 19:19:30 +05:00
Elizaryev Pavel
5031784237 roomlist.rs: replace "favourites" with "favorites" 2019-01-15 19:19:30 +05:00
Pavel Elizaryev
c157b76f50 Fix strings:
"Save as" should probably be "Save as…"
"You’ve been invited to join to "… → "to join", not "to join to".
Time formats should use a ratio symbol ∶ as suggested by the HIG
"Favorites" → "Favourites" (multiple occurrences)

https://gitlab.gnome.org/GNOME/fractal/issues/417
2019-01-15 19:19:30 +05:00
Bilal Elmoussaoui
ff411a5763 Appdata: add kudos tags
Documentation: https://gitlab.gnome.org/GNOME/gnome-software/blob/master/doc/kudos.md
2019-01-15 07:43:37 +00:00
Bilal Elmoussaoui
d8707df903 Appdata: improve the appdata file
specs: https://freedesktop.org/software/appstream/docs/chap-Quickstart.html
2019-01-15 07:43:37 +00:00
Bilal Elmoussaoui
ba288dcaf4 meson: add tests to validate appdata/desktop file 2019-01-14 07:57:42 +00:00
Piotr Drąg
9017488331 Update Polish translation 2019-01-12 12:42:51 +01:00
Piotr Drąg
f8ed2088f4 Update POTFILES.in 2019-01-09 19:50:12 +01:00
Julian Sparber
8afbc5cd15 attach: use common filechooser widget to attach file 2019-01-08 17:58:04 +01:00
Julian Sparber
985782b3b3 file dialog: add a common filepicker dialog 2019-01-08 17:57:10 +01:00
Daniel Garcia
bd0afef09d Updated Spanish translation 2019-01-08 09:54:43 +01:00
Anders Jonsson
ec53fe1ab9 Update Swedish translation 2019-01-07 22:03:05 +00:00
Alejandro Domínguez
ff7744efc0 Use .unwrap_or_default() instead of .unwrap_or() where possible 2019-01-06 17:48:37 +01:00
Alejandro Domínguez
043e7f5d44 Call String::new() instead of String::from("") or "".to_string() 2019-01-06 17:26:12 +01:00
Alejandro Domínguez
09894a81b6 Fix warning: unused mut 2019-01-06 04:13:33 +00:00
Alejandro Domínguez
280d585a25 Reformat Cargo.toml 2019-01-06 04:13:32 +00:00
Alejandro Domínguez
84b7026b2f Upgrade to Rust 2018 2019-01-06 04:13:32 +00:00
Julian Sparber
4205a6a980 rooms: cache rooms only when the roomlist is cleared 2019-01-05 15:29:15 +00:00