Make adding of signed-off-by footer for online changes customizable

Now that we migrated general user preferences to Git backend, we can
easily introduce new customization option: Signed-off-by footer for
changes created with inline edit feature:

* "Create Change" button on project screen
* "Edit Config" button on project screen
* "Follow-Up" button on change screen

Change-Id: Ifa94c18d5351196fbc741c6b16d0b129e2b4a6cb
This commit is contained in:
David Ostrovsky
2015-11-01 22:49:28 +01:00
committed by David Pursehouse
parent 5f8ce2c486
commit 5d8f62c938
9 changed files with 82 additions and 5 deletions

View File

@@ -51,6 +51,7 @@ public class GeneralPreferences extends JavaScriptObject {
p.sizeBarInChangeTable(d.sizeBarInChangeTable);
p.legacycidInChangeTable(d.legacycidInChangeTable);
p.muteCommonPathPrefixes(d.muteCommonPathPrefixes);
p.signedOffBy(d.signedOffBy);
p.reviewCategoryStrategy(d.getReviewCategoryStrategy());
p.diffView(d.getDiffView());
p.emailStrategy(d.emailStrategy);
@@ -109,6 +110,9 @@ public class GeneralPreferences extends JavaScriptObject {
public final native boolean muteCommonPathPrefixes()
/*-{ return this.mute_common_path_prefixes || false }-*/;
public final native boolean signedOffBy()
/*-{ return this.signed_off_by || false }-*/;
public final ReviewCategoryStrategy reviewCategoryStrategy() {
String s = reviewCategeoryStrategyRaw();
return s != null ? ReviewCategoryStrategy.valueOf(s) : ReviewCategoryStrategy.NONE;
@@ -176,6 +180,9 @@ public class GeneralPreferences extends JavaScriptObject {
public final native void muteCommonPathPrefixes(boolean s)
/*-{ this.mute_common_path_prefixes = s }-*/;
public final native void signedOffBy(boolean s)
/*-{ this.signed_off_by = s }-*/;
public final void reviewCategoryStrategy(ReviewCategoryStrategy s) {
reviewCategoryStrategyRaw(s != null ? s.toString() : null);
}