Changeset 7ba6f5a


Ignore:
Timestamp:
Jul 15, 2011 9:41:38 PM (9 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
a4ec6a5
Parents:
7fa874f
Message:

add gui option

Location:
apps/i2ptunnel
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/EditBean.java

    r7fa874f r7ba6f5a  
    2222import net.i2p.i2ptunnel.I2PTunnelHTTPClient;
    2323import net.i2p.i2ptunnel.I2PTunnelHTTPClientBase;
     24import net.i2p.i2ptunnel.I2PTunnelIRCClient;
    2425import net.i2p.i2ptunnel.TunnelController;
    2526import net.i2p.i2ptunnel.TunnelControllerGroup;
     
    171172    }
    172173   
     174    /** @since 0.8.9 */
     175    public boolean getDCC(int tunnel) {
     176        return getBooleanProperty(tunnel, I2PTunnelIRCClient.PROP_DCC);
     177    }
     178
    173179    public String getEncryptKey(int tunnel) {
    174180        return getProperty(tunnel, "i2cp.leaseSetKey", "");
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/web/IndexBean.java

    r7fa874f r7ba6f5a  
    2828import net.i2p.i2ptunnel.I2PTunnelHTTPClient;
    2929import net.i2p.i2ptunnel.I2PTunnelHTTPClientBase;
     30import net.i2p.i2ptunnel.I2PTunnelIRCClient;
    3031import net.i2p.i2ptunnel.TunnelController;
    3132import net.i2p.i2ptunnel.TunnelControllerGroup;
     
    676677    }
    677678
     679    /** @since 0.8.9 */
     680    public void setDCC(String moo) {
     681        _booleanOptions.add(I2PTunnelIRCClient.PROP_DCC);
     682    }
     683
    678684    protected static final String PROP_ENABLE_ACCESS_LIST = "i2cp.enableAccessList";
    679685    protected static final String PROP_ENABLE_BLACKLIST = "i2cp.enableBlackList";
     
    981987                config.setProperty("interface", "");
    982988        }
     989
     990        if ("ircclient".equals(_type)) {
     991                config.setProperty("option." + I2PTunnelIRCClient.PROP_DCC,
     992                                   "" + _booleanOptions.contains(I2PTunnelIRCClient.PROP_DCC));
     993        }
     994
    983995        return config;
    984996    }
     
    987999        "inbound.length", "outbound.length", "inbound.lengthVariance", "outbound.lengthVariance",
    9881000        "inbound.backupQuantity", "outbound.backupQuantity", "inbound.quantity", "outbound.quantity",
    989         "inbound.nickname", "outbound.nickname", "i2p.streaming.connectDelay", "i2p.streaming.maxWindowSize"
     1001        "inbound.nickname", "outbound.nickname", "i2p.streaming.connectDelay", "i2p.streaming.maxWindowSize",
     1002        I2PTunnelIRCClient.PROP_DCC
    9901003        };
    9911004    private static final String _booleanClientOpts[] = {
     
    10091022         PROP_MAX_STREAMS
    10101023        };
     1024
    10111025    protected static final Set _noShowSet = new HashSet(64);
    10121026    static {
  • apps/i2ptunnel/jsp/editClient.jsp

    r7fa874f r7ba6f5a  
    174174                <span class="comment"><%=intl._("(Check the Box for 'YES')")%></span>
    175175            </div>
     176         <% if ("ircclient".equals(tunnelType)) { %>
     177            <div id="startupField" class="rowItem">
     178                <label for="dcc" accesskey="d">
     179                    <%=intl._("Enable DCC")%>:
     180                </label>
     181                <input value="1" type="checkbox" id="startOnLoad" name="DCC" title="Enable DCC"<%=(editBean.getDCC(curTunnel) ? " checked=\"checked\"" : "")%> class="tickbox" />               
     182                <span class="comment"><%=intl._("(Check the Box for 'YES')")%></span>
     183            </div>
     184         <% } // ircclient %>
    176185           
    177186            <div class="footer">
Note: See TracChangeset for help on using the changeset viewer.