use of com.biglybt.pif.ui.config.ActionParameter in project BiglyBT by BiglySoftware.
the class SimpleAPIPlugin method initStage.
@Override
protected void initStage(int num) {
if (num == 1) {
BasicPluginConfigModel config = getConfigModel();
api_key = config.addStringParameter2("apikey", "plugin.simpleapi.apikey", "");
if (api_key.getValue().isEmpty()) {
api_key.setValue(createAPIKey());
}
ActionParameter change = config.addActionParameter2("plugin.simpleapi.apikey.new", "pairing.srp.setpw.doit");
change.addListener((n) -> {
api_key.setValue(createAPIKey());
updateTestParam();
});
test_param = config.addHyperlinkParameter2("plugin.simpleapi.test", "");
} else if (num == 2) {
updateTestParam();
}
}
Aggregations