@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix Control + Enter for Pontificate

Summary: Simplifies the Pontificate button and makes Control + Enter work again.

Test Plan: Submitted the form by clicking, hitting return, hitting control+enter.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Differential Revision: https://secure.phabricator.com/D5472

+9 -35
+1 -1
src/__celerity_resource_map__.php
··· 1206 1206 ), 1207 1207 'javelin-behavior-conpherence-pontificate' => 1208 1208 array( 1209 - 'uri' => '/res/e5a0ce39/rsrc/js/application/conpherence/behavior-pontificate.js', 1209 + 'uri' => '/res/a5f5b42c/rsrc/js/application/conpherence/behavior-pontificate.js', 1210 1210 'type' => 'js', 1211 1211 'requires' => 1212 1212 array(
-2
src/__phutil_library_map__.php
··· 238 238 'ConpherenceParticipantQuery' => 'applications/conpherence/query/ConpherenceParticipantQuery.php', 239 239 'ConpherenceParticipationStatus' => 'applications/conpherence/constants/ConpherenceParticipationStatus.php', 240 240 'ConpherencePeopleMenuEventListener' => 'applications/conpherence/events/ConpherencePeopleMenuEventListener.php', 241 - 'ConpherencePontificateControl' => 'applications/conpherence/view/ConpherencePontificateControl.php', 242 241 'ConpherenceReplyHandler' => 'applications/conpherence/mail/ConpherenceReplyHandler.php', 243 242 'ConpherenceSettings' => 'applications/conpherence/constants/ConpherenceSettings.php', 244 243 'ConpherenceThread' => 'applications/conpherence/storage/ConpherenceThread.php', ··· 1948 1947 'ConpherenceParticipantQuery' => 'PhabricatorOffsetPagedQuery', 1949 1948 'ConpherenceParticipationStatus' => 'ConpherenceConstants', 1950 1949 'ConpherencePeopleMenuEventListener' => 'PhutilEventListener', 1951 - 'ConpherencePontificateControl' => 'AphrontFormControl', 1952 1950 'ConpherenceReplyHandler' => 'PhabricatorMailReplyHandler', 1953 1951 'ConpherenceSettings' => 'ConpherenceConstants', 1954 1952 'ConpherenceThread' =>
+4 -2
src/applications/conpherence/controller/ConpherenceViewController.php
··· 82 82 ->setID($form_id) 83 83 ->setAction($update_uri) 84 84 ->setFlexible(true) 85 + ->addSigil('conpherence-pontificate') 86 + ->setWorkflow(true) 85 87 ->setUser($user) 86 88 ->addHiddenInput('action', 'message') 87 89 ->addHiddenInput('latest_transaction_id', $latest_transaction_id) ··· 90 92 ->setUser($user) 91 93 ->setName('text')) 92 94 ->appendChild( 93 - id(new ConpherencePontificateControl()) 94 - ->setFormID($form_id)) 95 + id(new AphrontFormSubmitControl()) 96 + ->setValue(pht('Pontificate'))) 95 97 ->render(); 96 98 97 99 $scrollbutton = javelin_tag(
-29
src/applications/conpherence/view/ConpherencePontificateControl.php
··· 1 - <?php 2 - 3 - final class ConpherencePontificateControl extends AphrontFormControl { 4 - 5 - private $formID; 6 - 7 - public function setFormID($form_id) { 8 - $this->formID = $form_id; 9 - return $this; 10 - } 11 - public function getFormID() { 12 - return $this->formID; 13 - } 14 - 15 - protected function getCustomControlClass() { 16 - return 'aphront-form-control-submit'; 17 - } 18 - 19 - protected function renderInput() { 20 - 21 - return javelin_tag( 22 - 'button', 23 - array ( 24 - 'sigil' => 'conpherence-pontificate', 25 - ), 26 - pht('Pontificate')); 27 - } 28 - 29 - }
+4 -1
webroot/rsrc/js/application/conpherence/behavior-pontificate.js
··· 49 49 .start(); 50 50 }; 51 51 52 - JX.Stratcom.listen('click', 'conpherence-pontificate', onsubmit); 52 + JX.Stratcom.listen( 53 + ['submit', 'didSyntheticSubmit'], 54 + 'conpherence-pontificate', 55 + onsubmit); 53 56 54 57 });