1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-11 01:12:41 +01:00
phorge-phorge/src/view
epriestley 67482fd19d Continue modernizing application access to user preferences
Summary:
Ref T4103. This is just incremental cleanup:

  - Add "internal" settings, which aren't editable via the UI. They can still do validation and run through the normal pathway. Move a couple settings to use this.
  - Remove `getPreference()` on `PhabricatorUser`, which was a sort of prototype version of `getUserSetting()`.
  - Make `getUserSetting()` validate setting values before returning them, to improve robustness if we change allowable values later.
  - Add a user setting cache, since reading user settings was getting fairly expensive on Calendar.
  - Improve performance of setting validation for timezone setting (don't require building/computing all timezone offsets).
  - Since we have the cache anyway, make the timezone override a little more general in its approach.
  - Move editor stuff to use `getUserSetting()`.

Test Plan:
  - Changed search scopes.
  - Reconciled local and server timezone settings by ignoring and changing timezones.
  - Changed date/time settings, browsed Calendar, queried date ranges.
  - Verified editor links generate properly in Diffusion.
  - Browsed around with time/date settings looking at timestamps.
  - Grepped for `getPreference()`, nuked all the ones coming off `$user` or `$viewer` that I could find.
  - Changed accessiblity to high-contrast colors.
  - Ran all unit tests.
  - Grepped for removed constants.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T4103

Differential Revision: https://secure.phabricator.com/D16015
2016-06-04 14:37:56 -07:00
..
__tests__ Make translation, timezone and pronoun into real settings 2016-06-02 06:29:47 -07:00
control Give unit test results their own table in Differential 2016-02-29 14:27:22 -08:00
extension Introduce "Curtain" views, panels, and extensions 2016-03-06 09:27:55 -08:00
form Continue modernizing application access to user preferences 2016-06-04 14:37:56 -07:00
layout Convert Maniphest to curtain view 2016-03-06 10:32:18 -08:00
page Continue modernizing application access to user preferences 2016-06-04 14:37:56 -07:00
phui Continue modernizing application access to user preferences 2016-06-04 14:37:56 -07:00
widget Move PhabricatorHovercard to PHUIHovercard 2016-02-03 16:26:30 +00:00
AphrontDialogView.php Add role=dialog to all dialogs 2016-05-31 12:22:04 -07:00
AphrontJavelinView.php Various linter fixes 2015-05-20 07:27:41 +10:00
AphrontNullView.php Provide hasChildren() to replace isEmptyContent() 2013-08-12 07:51:01 -07:00
AphrontTagView.php Disambiguate isEmpty() 2016-01-31 15:20:04 -08:00
AphrontView.php Give AphrontTagView a getViewer(), deprecate getUser() 2016-03-06 09:27:38 -08:00
viewutils.php Continue modernizing application access to user preferences 2016-06-04 14:37:56 -07:00