Commit graph

16 commits

Author SHA1 Message Date
Michael James Gratton
cbe6e0ba9b Revert "Merge branch 'mjog/558-webkit-shared-process' into 'mainline'"
Revert merge request GNOME/geary!374 for now since the shared process
model breaks old-style WebProcess message handler IPC.

This can be un-reverted when out JS is ported to the new Messages API
that is landing in WebKitGTK 2.28.

This reverts commit e4a5b85698, reversing
changes made to 66f6525480.
2020-02-13 12:56:52 +11:00
Michael Gratton
ceb9c9764a Rename ClientWebView to Components.WebView per code style 2019-11-26 14:26:03 +11:00
Michael Gratton
ca6cbecb83 Add manual Components.Validator::validator method
Support manual validation where needed, add unit tests.

This also slightly changes the behaviour of non-required field, since
an empty non-required field should be valid.
2019-11-20 17:11:14 +11:00
Michael Gratton
56876365ba Rename GearyApplication class and source to match code style
Rename `GearyApplication` => `Application.Client` and
`geary-application.vala to `application-client.vala`. Update call sites
and test cases.
2019-11-17 21:38:29 +11:00
Michael Gratton
29042bb2d8 Move composer classes into their own namespace
Rename all composer classes prefixed with "Composer" so that the prefix
is a namespace instead. This increases the compartmentalisation of the
classes, making `internal` a useful member modifier and makes them
consistent with the code style guide.
2019-11-17 20:00:02 +11:00
Michael Gratton
e426517b30 Rename Config class and source file to match code style
Rename `Configuration` => `Application.Configuration` and
`geary-config.vala to `application-config.vala`. Update call sites and
test cases.
2019-11-17 16:53:42 +11:00
Michael Gratton
8206cf434d Remove Flatpak test locale hack, just use en_US.UTF-8 for now
FDO 19.08 runtime now includes C.UTF-8 locale, but since Fedora
now ships one that collates high-bit chars, it differs compared
to Debian et al's and FDO.

As a result, just use en_US.UTF-8 for now, probably until glibc
actually ships it and so they all agree.
2019-10-16 13:36:29 +11:00
Michael Gratton
da6ac828bd Move Geary.JS package into client as Util.JS
The only reason it was in the engine was so it could be used by both
the client and the web extension, without worrying about the
webkit2gtk and webkit2gtk_web_extension packages conflicting. However
it didn't really belong there, and added a dependency for the engine
on javascriptcoregtk which doesn't belong. So this fixes all that.
2019-07-21 10:00:32 +10:00
Michael Gratton
788a06144f Ensure test drivers all have sane locales set 2019-06-22 14:08:03 +10:00
Michael Gratton
d4c29c72d7 Add unit tests for app path accessors 2019-04-21 11:13:01 +10:00
Michael Gratton
73159ba091 Add new generic LRU cache to the client 2019-04-08 10:26:04 +10:00
Michael Gratton
6c8f192148 Attempt to de-mangle From names from Mailman, GitLab, etc
Some software like the above will mangle From mailbox names by appending
"via Some Service" to the From mailbox name. This messes up generating
default avatars for the actual people sending these messages, so
attempt to de-mangle the names.

This involves moving primary originator determination from the engine
to the client, since it's now a policy thing. Add unit tests.
2019-03-09 20:17:01 +11:00
Michael Gratton
76ee07595d Make avatar code a bit more robust in the face of bad input
Don't try to dray null initials, actually return null per API contract
when no initials can be found, don't include non-alphanumerics in the
initials. Add test case.
2019-03-09 20:17:01 +11:00
Michael James Gratton
5305c27ca7 Move AccountManager and related objects into Accounts package.
This makes the manager consistent with the source file naming convention
and the new account UI classes.
2018-11-30 23:49:30 +11:00
Michael James Gratton
74fa29b73f Tidy up Geary.AccountInformation creation.
Pass service provider to ctor so we can make the service provider
property immutable. Fill in service label in ctor so it's always set to
something useful. Move creating orphans from Engine to AccountManager
since it exists only to assign an internal id for new accounts, so it
should handled by the account manager anyway.
2018-11-30 23:49:30 +11:00
Michael James Gratton
878b9aacae Split test running up into test-engine and test-client.
This allows us to compile the engine tests against the internal VAPI, so
we can unit test internal classes.

* CMakeLists.txt: Add top-level targets test-engine-run and
  test-client-run that execute the respective test binaries. Make
  the tests target depend on them and make them depend on their
  binaries.

* Makefile.in: Add test-client and test-engin targets for convenience.

* src/CMakeLists.txt: Make the right invocation of valac to generate a
  correct geary-engine-internal.vapi. Make gsettings schema generation
  depend on geary-client so it exists for test-client if the main binary
  hasn't been built.

* test/CMakeLists.txt: Split everything up into to builds, one for
  test-engine and the other for test-client. Use geary-engine-internal
  when building test-engine for access to internal classes and members.

* test/engine/util-idle-manager-test.vala,
  test/engine/util-timeout-manager-test.vala: Use Glib MainContext rather
  than the GTK main loop for pumping events so the test cases compile
  without GTK.

* test/test-engine.vala, test/test-client.vala: New main source file for
  test binaries based on old main.vala.
2017-12-18 14:49:04 +11:00
Renamed from test/main.vala (Browse further)