Fossil SCM

Improvements to the HTML generated for the /xfersetup page.

drh 2015-03-17 17:10 trunk merge
Commit f215075a47e34aa48ecf111b6e8cad759c40a14e
--- skins/blitz/css.txt
+++ skins/blitz/css.txt
@@ -599,10 +599,11 @@
599599
-moz-appearance: none;
600600
appearance: none;
601601
}
602602
603603
textarea {
604
+ height: inherit;
604605
min-height: 65px;
605606
padding-top: 6px;
606607
padding-bottom: 6px;
607608
}
608609
609610
--- skins/blitz/css.txt
+++ skins/blitz/css.txt
@@ -599,10 +599,11 @@
599 -moz-appearance: none;
600 appearance: none;
601 }
602
603 textarea {
 
604 min-height: 65px;
605 padding-top: 6px;
606 padding-bottom: 6px;
607 }
608
609
--- skins/blitz/css.txt
+++ skins/blitz/css.txt
@@ -599,10 +599,11 @@
599 -moz-appearance: none;
600 appearance: none;
601 }
602
603 textarea {
604 height: inherit;
605 min-height: 65px;
606 padding-top: 6px;
607 padding-bottom: 6px;
608 }
609
610
--- skins/blitz_no_logo/css.txt
+++ skins/blitz_no_logo/css.txt
@@ -599,10 +599,11 @@
599599
-moz-appearance: none;
600600
appearance: none;
601601
}
602602
603603
textarea {
604
+ height: inherit;
604605
min-height: 65px;
605606
padding-top: 6px;
606607
padding-bottom: 6px;
607608
}
608609
609610
--- skins/blitz_no_logo/css.txt
+++ skins/blitz_no_logo/css.txt
@@ -599,10 +599,11 @@
599 -moz-appearance: none;
600 appearance: none;
601 }
602
603 textarea {
 
604 min-height: 65px;
605 padding-top: 6px;
606 padding-bottom: 6px;
607 }
608
609
--- skins/blitz_no_logo/css.txt
+++ skins/blitz_no_logo/css.txt
@@ -599,10 +599,11 @@
599 -moz-appearance: none;
600 appearance: none;
601 }
602
603 textarea {
604 height: inherit;
605 min-height: 65px;
606 padding-top: 6px;
607 padding-bottom: 6px;
608 }
609
610
+18 -17
--- src/xfersetup.c
+++ src/xfersetup.c
@@ -33,11 +33,11 @@
3333
return;
3434
}
3535
3636
style_header("Transfer Setup");
3737
38
- @ <table border="0" cellspacing="20">
38
+ @ <table class="xfersetup">
3939
setup_menu_entry("Common", "xfersetup_com",
4040
"Common TH1 code run before all transfer request processing.");
4141
setup_menu_entry("Push", "xfersetup_push",
4242
"Specific TH1 code to run after \"push\" transfer requests.");
4343
setup_menu_entry("Commit", "xfersetup_commit",
@@ -60,33 +60,33 @@
6060
syncFlags = SYNC_PUSH | SYNC_PULL;
6161
zButton = "Synchronize";
6262
zWarning = mprintf("WARNING: Pushing to \"%s\" is enabled.",
6363
g.url.canonical);
6464
}
65
- if( P("sync") ){
66
- user_select();
67
- url_enable_proxy(0);
68
- client_sync(syncFlags, 0, 0);
69
- }
70
- @ <p>Press the %h(zButton) button below to synchronize with the
71
- @ "%h(g.url.canonical)" repository now. This may be useful when
72
- @ testing the various transfer scripts.</p>
73
- @ <p>You can use the "http -async" command in your scripts, but
74
- @ make sure the "th1-uri-regexp" setting is set first.</p>
65
+ @ <p>Press the <strong>%h(zButton)</strong> button below to
66
+ @ synchronize with the <em>%h(g.url.canonical)</em> repository now.<br/>
67
+ @ This may be useful when testing the various transfer scripts.</p>
68
+ @ <p>You can use the <code>http -async</code> command in your scripts, but
69
+ @ make sure the <code>th1-uri-regexp</code> setting is set first.</p>
7570
if( zWarning ){
7671
@
7772
@ <big><b>%h(zWarning)</b></big>
7873
free(zWarning);
7974
}
8075
@
81
- @ <blockquote>
8276
@ <form method="post" action="%s(g.zTop)/%s(g.zPath)"><div>
8377
login_insert_csrf_secret();
8478
@ <input type="submit" name="sync" value="%h(zButton)" />
8579
@ </div></form>
86
- @ </blockquote>
8780
@
81
+ if( P("sync") ){
82
+ user_select();
83
+ url_enable_proxy(0);
84
+ @ <pre class="xfersetup">
85
+ client_sync(syncFlags, 0, 0);
86
+ @ </pre>
87
+ }
8888
}
8989
9090
style_footer();
9191
}
9292
@@ -137,18 +137,18 @@
137137
}
138138
@ <form action="%s(g.zTop)/%s(g.zPath)" method="post"><div>
139139
login_insert_csrf_secret();
140140
@ <p>%s(zDesc)</p>
141141
@ <textarea name="x" rows="%d(height)" cols="80">%h(z)</textarea>
142
- @ <blockquote><p>
142
+ @ <p>
143143
@ <input type="submit" name="submit" value="Apply Changes" />
144144
@ <input type="submit" name="clear" value="Revert To Default" />
145145
@ <input type="submit" name="setup" value="Cancel" />
146
- @ </p></blockquote>
146
+ @ </p>
147147
@ </div></form>
148
- @ <hr />
149148
if ( zDfltValue ){
149
+ @ <hr />
150150
@ <h2>Default %s(zTitle)</h2>
151151
@ <blockquote><pre>
152152
@ %h(zDfltValue)
153153
@ </pre></blockquote>
154154
}
@@ -181,11 +181,12 @@
181181
/*
182182
** WEBPAGE: xfersetup_push
183183
*/
184184
void xfersetup_push_page(void){
185185
static const char zDesc[] =
186
- @ Enter TH1 script that runs after processing "push" transfer requests.
186
+ @ Enter TH1 script that runs after processing <strong>push</strong>
187
+ @ transfer requests.
187188
;
188189
xfersetup_generic(
189190
"Transfer Push Script",
190191
"xfer-push-script",
191192
zDefaultXferPush,
192193
--- src/xfersetup.c
+++ src/xfersetup.c
@@ -33,11 +33,11 @@
33 return;
34 }
35
36 style_header("Transfer Setup");
37
38 @ <table border="0" cellspacing="20">
39 setup_menu_entry("Common", "xfersetup_com",
40 "Common TH1 code run before all transfer request processing.");
41 setup_menu_entry("Push", "xfersetup_push",
42 "Specific TH1 code to run after \"push\" transfer requests.");
43 setup_menu_entry("Commit", "xfersetup_commit",
@@ -60,33 +60,33 @@
60 syncFlags = SYNC_PUSH | SYNC_PULL;
61 zButton = "Synchronize";
62 zWarning = mprintf("WARNING: Pushing to \"%s\" is enabled.",
63 g.url.canonical);
64 }
65 if( P("sync") ){
66 user_select();
67 url_enable_proxy(0);
68 client_sync(syncFlags, 0, 0);
69 }
70 @ <p>Press the %h(zButton) button below to synchronize with the
71 @ "%h(g.url.canonical)" repository now. This may be useful when
72 @ testing the various transfer scripts.</p>
73 @ <p>You can use the "http -async" command in your scripts, but
74 @ make sure the "th1-uri-regexp" setting is set first.</p>
75 if( zWarning ){
76 @
77 @ <big><b>%h(zWarning)</b></big>
78 free(zWarning);
79 }
80 @
81 @ <blockquote>
82 @ <form method="post" action="%s(g.zTop)/%s(g.zPath)"><div>
83 login_insert_csrf_secret();
84 @ <input type="submit" name="sync" value="%h(zButton)" />
85 @ </div></form>
86 @ </blockquote>
87 @
 
 
 
 
 
 
 
88 }
89
90 style_footer();
91 }
92
@@ -137,18 +137,18 @@
137 }
138 @ <form action="%s(g.zTop)/%s(g.zPath)" method="post"><div>
139 login_insert_csrf_secret();
140 @ <p>%s(zDesc)</p>
141 @ <textarea name="x" rows="%d(height)" cols="80">%h(z)</textarea>
142 @ <blockquote><p>
143 @ <input type="submit" name="submit" value="Apply Changes" />
144 @ <input type="submit" name="clear" value="Revert To Default" />
145 @ <input type="submit" name="setup" value="Cancel" />
146 @ </p></blockquote>
147 @ </div></form>
148 @ <hr />
149 if ( zDfltValue ){
 
150 @ <h2>Default %s(zTitle)</h2>
151 @ <blockquote><pre>
152 @ %h(zDfltValue)
153 @ </pre></blockquote>
154 }
@@ -181,11 +181,12 @@
181 /*
182 ** WEBPAGE: xfersetup_push
183 */
184 void xfersetup_push_page(void){
185 static const char zDesc[] =
186 @ Enter TH1 script that runs after processing "push" transfer requests.
 
187 ;
188 xfersetup_generic(
189 "Transfer Push Script",
190 "xfer-push-script",
191 zDefaultXferPush,
192
--- src/xfersetup.c
+++ src/xfersetup.c
@@ -33,11 +33,11 @@
33 return;
34 }
35
36 style_header("Transfer Setup");
37
38 @ <table class="xfersetup">
39 setup_menu_entry("Common", "xfersetup_com",
40 "Common TH1 code run before all transfer request processing.");
41 setup_menu_entry("Push", "xfersetup_push",
42 "Specific TH1 code to run after \"push\" transfer requests.");
43 setup_menu_entry("Commit", "xfersetup_commit",
@@ -60,33 +60,33 @@
60 syncFlags = SYNC_PUSH | SYNC_PULL;
61 zButton = "Synchronize";
62 zWarning = mprintf("WARNING: Pushing to \"%s\" is enabled.",
63 g.url.canonical);
64 }
65 @ <p>Press the <strong>%h(zButton)</strong> button below to
66 @ synchronize with the <em>%h(g.url.canonical)</em> repository now.<br/>
67 @ This may be useful when testing the various transfer scripts.</p>
68 @ <p>You can use the <code>http -async</code> command in your scripts, but
69 @ make sure the <code>th1-uri-regexp</code> setting is set first.</p>
 
 
 
 
 
70 if( zWarning ){
71 @
72 @ <big><b>%h(zWarning)</b></big>
73 free(zWarning);
74 }
75 @
 
76 @ <form method="post" action="%s(g.zTop)/%s(g.zPath)"><div>
77 login_insert_csrf_secret();
78 @ <input type="submit" name="sync" value="%h(zButton)" />
79 @ </div></form>
 
80 @
81 if( P("sync") ){
82 user_select();
83 url_enable_proxy(0);
84 @ <pre class="xfersetup">
85 client_sync(syncFlags, 0, 0);
86 @ </pre>
87 }
88 }
89
90 style_footer();
91 }
92
@@ -137,18 +137,18 @@
137 }
138 @ <form action="%s(g.zTop)/%s(g.zPath)" method="post"><div>
139 login_insert_csrf_secret();
140 @ <p>%s(zDesc)</p>
141 @ <textarea name="x" rows="%d(height)" cols="80">%h(z)</textarea>
142 @ <p>
143 @ <input type="submit" name="submit" value="Apply Changes" />
144 @ <input type="submit" name="clear" value="Revert To Default" />
145 @ <input type="submit" name="setup" value="Cancel" />
146 @ </p>
147 @ </div></form>
 
148 if ( zDfltValue ){
149 @ <hr />
150 @ <h2>Default %s(zTitle)</h2>
151 @ <blockquote><pre>
152 @ %h(zDfltValue)
153 @ </pre></blockquote>
154 }
@@ -181,11 +181,12 @@
181 /*
182 ** WEBPAGE: xfersetup_push
183 */
184 void xfersetup_push_page(void){
185 static const char zDesc[] =
186 @ Enter TH1 script that runs after processing <strong>push</strong>
187 @ transfer requests.
188 ;
189 xfersetup_generic(
190 "Transfer Push Script",
191 "xfer-push-script",
192 zDefaultXferPush,
193

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button