You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(58) |
Dec
(33) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
|
Feb
|
Mar
(13) |
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(15) |
Nov
(4) |
Dec
(4) |
2002 |
Jan
|
Feb
(31) |
Mar
(4) |
Apr
(19) |
May
|
Jun
|
Jul
|
Aug
(2) |
Sep
(4) |
Oct
(129) |
Nov
(66) |
Dec
|
From: Thomas J. <fa...@ap...> - 2002-11-05 22:35:25
|
Update of /var/lib/cvs/bWF2/src/de/bchat/bwf2/theming In directory apollo:/tmp/cvs-serv30954 Modified Files: bWF2Theme.java Log Message: wheh. many small fixes today, but in the end, it looks somewhat better now. this appends newlines to the template lines read in, so the html source stays somehow readable Index: bWF2Theme.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/de/bchat/bwf2/theming/bWF2Theme.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- bWF2Theme.java 5 Nov 2002 01:00:21 -0000 1.1 +++ bWF2Theme.java 5 Nov 2002 22:35:14 -0000 1.2 @@ -54,7 +54,7 @@ String tmp = ""; BufferedReader in = new BufferedReader(new FileReader(new File(abs_filename))); while((tmp = in.readLine()) != null) { - content.append(tmp); + content.append(tmp+"\n"); } objects.put(object, (content.toString().replaceAll("<%--THEMEROOT--%>",themeroot))); } catch(FileNotFoundException fnfe) { |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:33:53
|
Update of /var/lib/cvs/bWF2/src/de/bchat/database In directory apollo:/tmp/cvs-serv30856 Modified Files: bchatDatabase.java Log Message: OBITWO ERROR ;) Index: bchatDatabase.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/de/bchat/database/bchatDatabase.java,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- bchatDatabase.java 5 Nov 2002 00:58:17 -0000 1.14 +++ bchatDatabase.java 5 Nov 2002 22:33:45 -0000 1.15 @@ -149,7 +149,7 @@ user.setUserID(uid); //set lastlogin+flogins, re-set to now/0. user.setFailedLogins(failedlogins); user.setLastLogin(lastlogin); - stmt.execute("UPDATE udata SET failedlogins='0', lastlogin=NOW() WHERE ID='"+uid+"'"); + stmt.execute("UPDATE udata SET failedlogins=0, lastlogin=NOW() WHERE ID='"+uid+"'"); ret = true; } else { //a valid username tried to log in and failed. failedlogins++; |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:33:17
|
Update of /var/lib/cvs/bWF2/src/de/bchat/net In directory apollo:/tmp/cvs-serv30781 Modified Files: bchatConnection.java Log Message: cancel waiting for connection closing after timeout Index: bchatConnection.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/de/bchat/net/bchatConnection.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- bchatConnection.java 1 Nov 2002 20:14:36 -0000 1.3 +++ bchatConnection.java 5 Nov 2002 22:33:09 -0000 1.4 @@ -122,10 +122,16 @@ public void closeChatview() { closeChatview = true; + int count = 0; while(openChatview) { try { - log.debug("chatview closing requested, waiting for readloop to finish..."); - Thread.sleep(5000); + if(count++ > 5) { + log.error("tried to close chatview 5 times, but it refused to. bye-bye!"); + return; + } else { + log.debug("chatview closing requested, waiting for readloop to finish..."); + Thread.sleep(5000); + } } catch (InterruptedException irex) { log.error("Interrupted while waiting for chatview to close!"); } |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:32:31
|
Update of /var/lib/cvs/bWF2/src/taglibs/bWF2Theme In directory apollo:/tmp/cvs-serv30731 Modified Files: Select.java Log Message: remove silly debugging output Index: Select.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/taglibs/bWF2Theme/Select.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- Select.java 5 Nov 2002 01:02:10 -0000 1.1 +++ Select.java 5 Nov 2002 22:32:23 -0000 1.2 @@ -16,7 +16,6 @@ } public int doStartTag() throws JspException { - log.debug("Set Theme " + name); return SKIP_BODY; } } |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:32:11
|
Update of /var/lib/cvs/bWF2/src/taglibs/bWF2Theme In directory apollo:/tmp/cvs-serv30662 Modified Files: Box.java Log Message: handle a not-set width Index: Box.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/taglibs/bWF2Theme/Box.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- Box.java 5 Nov 2002 01:02:10 -0000 1.1 +++ Box.java 5 Nov 2002 22:32:03 -0000 1.2 @@ -17,7 +17,7 @@ static Logger log = Logger.getLogger("bWF2Theme-Box"); public void setwidth(String width) { - this.width = width; + this.width = "width=\""+width+"\""; } public void setpart(String part) { |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:31:36
|
Update of /var/lib/cvs/bWF2/web/WEB-INF In directory apollo:/tmp/cvs-serv30619 Modified Files: themes.properties Log Message: added the simple theme Index: themes.properties =================================================================== RCS file: /var/lib/cvs/bWF2/web/WEB-INF/themes.properties,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- themes.properties 5 Nov 2002 00:45:48 -0000 1.1 +++ themes.properties 5 Nov 2002 22:31:29 -0000 1.2 @@ -14,3 +14,10 @@ blue-heart.file.box_start=box_start.html blue-heart.file.box_stop=box_stop.html +simple +simple.author=fake +simple.file.header=header.html +simple.file.footer=footer.html +simple.file.box_item=box_item.html +simple.file.box_start=box_start.html +simple.file.box_stop=box_stop.html |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:31:13
|
Update of /var/lib/cvs/bWF2/web In directory apollo:/tmp/cvs-serv30540 Modified Files: show_user_data.jsp Log Message: add theming tags Index: show_user_data.jsp =================================================================== RCS file: /var/lib/cvs/bWF2/web/show_user_data.jsp,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- show_user_data.jsp 5 Nov 2002 00:43:58 -0000 1.2 +++ show_user_data.jsp 5 Nov 2002 22:31:06 -0000 1.3 @@ -6,6 +6,7 @@ <%@page import="java.text.DateFormat"%> <%@page import="java.util.Locale"%> <%@taglib uri="/i18n" prefix="i18n" %> +<%@taglib uri="/themes" prefix="theme" %> <jsp:useBean id="user" scope="session" class="de.bchat.common.bchatUser"/> <% boolean extended_mode = false; @@ -48,8 +49,8 @@ DateFormat df = DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.SHORT); %> <i18n:bundle baseName="i18nResources" locale="<%=user.getLocale()%>"/> -<html> -<head><title>Benutzerdaten</title></head> +<theme:select themeName="<%=user.getTheme()%>"/> +<theme:header pageTitle="Benutzerdaten"/> <body> <center> <a href="community.jsp">zurueck</a><br><br> @@ -59,6 +60,7 @@ </font> <% } %> <br><br> +<theme:box part="start"/> <% if(is_public) { %> <table border="1"> <tr> @@ -127,8 +129,8 @@ </tr> </table> <% } %> +<theme:box part="stop"/> <br><br> <a href="CommunityLogout"><i18n:message key="bchat.navigation.LOGOUT"/></a> </center> -</body> -</html> +<theme:footer/> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:30:30
|
Update of /var/lib/cvs/bWF2/web In directory apollo:/tmp/cvs-serv30464 Modified Files: search_user.jsp Log Message: add theming tags Index: search_user.jsp =================================================================== RCS file: /var/lib/cvs/bWF2/web/search_user.jsp,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- search_user.jsp 2 Nov 2002 06:58:15 -0000 1.1 +++ search_user.jsp 5 Nov 2002 22:30:22 -0000 1.2 @@ -3,6 +3,7 @@ <%@page import="java.util.HashMap"%> <%@page import="de.bchat.database.bchatDatabase"%> <%@taglib uri="/i18n" prefix="i18n"%> +<%@taglib uri="/themes" prefix="theme"%> <jsp:useBean id="user" scope="session" class="de.bchat.common.bchatUser"/> <% if(user == null || session.isNew() || user.getUserID() < 1) { @@ -17,15 +18,17 @@ String err_msg = (String)request.getAttribute("err_msg"); %> <i18n:bundle baseName="i18nResources" locale="<%=user.getLocale()%>"/> -<html> -<head><title>Search for users</title></head> -<body> +<theme:select themeName="<%=user.getTheme()%>"/> +<theme:header pageTitle="Benutzer suchen"/> <center> <% if(err_msg != null && !err_msg.trim().equals("")) { %> <font color="red"> <%=err_msg%> </font> <% } %> +<br><br> +<theme:box part="start"/> +<theme:box part="item" title="Benutzer suchen"/> <FORM action="UserSearch" method="post"> <table> <tr> @@ -35,7 +38,9 @@ </tr> </table> </form> - +<theme:box part="stop"/> +<br><br> +<theme:box part="start"/> <% if(request.getParameter("search") != null) { //submitted if (request.getAttribute("results") != null) { // results returned @@ -59,7 +64,5 @@ } } %> - - -</body> -</html> +<theme:box part="stop"/> +<theme:footer/> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:30:10
|
Update of /var/lib/cvs/bWF2/web In directory apollo:/tmp/cvs-serv30369 Modified Files: index.jsp Log Message: add theming tags Index: index.jsp =================================================================== RCS file: /var/lib/cvs/bWF2/web/index.jsp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- index.jsp 24 Oct 2002 18:37:22 -0000 1.5 +++ index.jsp 5 Nov 2002 22:30:02 -0000 1.6 @@ -1,6 +1,6 @@ <%@page contentType="text/html"%> <%@taglib uri="/i18n" prefix="i18n"%> -<%@page import="java.util.Locale"%> +<%@taglib uri="/themes" prefix="theme"%> <i18n:bundle baseName="i18nResources" scope="page"/> <% String err_msg = (String)request.getAttribute("err_msg"); @@ -17,6 +17,11 @@ <% } %> <br><br> <i18n:message key="bchat.login.WELCOME"/><br><br> +<theme:select themeName="default"/> +<theme:header pageTitle="bchat Login"/> + +<theme:box part="start"/> + <form action="CommunityLogin" method="post"> <table border="0"> <tr><td align="right"><i18n:message key="bchat.login.USERNAME"/>:</td> @@ -33,6 +38,6 @@ </form> <br> <a href="signup.jsp"><i18n:message key="bchat.login.SIGNUP"/></a> +<theme:box part="stop"/> </center> -</body> -</html> +<theme:footer/> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:29:53
|
Update of /var/lib/cvs/bWF2/web In directory apollo:/tmp/cvs-serv30324 Modified Files: edit_user_data.jsp Log Message: add theming tags Index: edit_user_data.jsp =================================================================== RCS file: /var/lib/cvs/bWF2/web/edit_user_data.jsp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- edit_user_data.jsp 5 Nov 2002 00:43:58 -0000 1.5 +++ edit_user_data.jsp 5 Nov 2002 22:29:46 -0000 1.6 @@ -57,6 +57,7 @@ </font> <% } %> <br><br> +<theme:box part="start"/> <form action="EditUserData" method="post"> <table border="1"> <tr> @@ -162,6 +163,7 @@ <input type="hidden" name="userID" value="<%=userToEdit.getUserID()%>"> <% } %> </form> +<theme:box part="stop"/> <br><br> <a href="CommunityLogout"><i18n:message key="bchat.navigation.LOGOUT"/></a> </center> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:29:21
|
Update of /var/lib/cvs/bWF2/web In directory apollo:/tmp/cvs-serv30275 Modified Files: community.jsp Log Message: add a link to the admin area Index: community.jsp =================================================================== RCS file: /var/lib/cvs/bWF2/web/community.jsp,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- community.jsp 5 Nov 2002 00:43:58 -0000 1.7 +++ community.jsp 5 Nov 2002 22:29:13 -0000 1.8 @@ -40,6 +40,10 @@ <a href="search_user.jsp">Benutzer suchen</a> <br><br> <a href="chat/chat.jsp">Chat</a> +<% if (user.getAdmin()) { %> + <br><br> + <a href="admin/index.jsp">Admin Area</a> +<% } %> <theme:box part="stop"/> <br><br><br> <a href="CommunityLogout"><i18n:message key="bchat.navigation.LOGOUT"/></a> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:28:36
|
Update of /var/lib/cvs/bWF2/web/themes/default In directory apollo:/tmp/cvs-serv30165/default Modified Files: box_item.html box_start.html Log Message: minor fixes. html-snippets... Index: box_item.html =================================================================== RCS file: /var/lib/cvs/bWF2/web/themes/default/box_item.html,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- box_item.html 5 Nov 2002 00:55:56 -0000 1.1 +++ box_item.html 5 Nov 2002 22:28:29 -0000 1.2 @@ -2,7 +2,7 @@ <TD width="32" background="<%--THEMEROOT--%>/images/box/text_right_back.gif"><IMG src="<%--THEMEROOT--%>/images/blank.gif" width="1" height="1" alt="" border="0"></TD> </TR><TR> <TD width="31"><IMG src="<%--THEMEROOT--%>/images/box/item_left_pic.gif" width="31" height="27" alt="" border="0"></TD> -<TD width="100%" nowrap background="<%--THEMEROOT--%>/images/box/item_mid_back.gif"><B><!--TITLE--></B></TD> +<TD nowrap background="<%--THEMEROOT--%>/images/box/item_mid_back.gif"><B><!--TITLE--></B></TD> <TD width="32"><IMG src="<%--THEMEROOT--%>/images/box/item_right_pic.gif" width="32" height=27 alt="" border="0"></TD> </TR><TR> <TD width="31" background="<%--THEMEROOT--%>/images/box/text_left_back.gif"><IMG src="<%--THEMEROOT--%>/images/blank.gif" width="1" height="1" alt="" border="0"></TD> Index: box_start.html =================================================================== RCS file: /var/lib/cvs/bWF2/web/themes/default/box_start.html,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- box_start.html 5 Nov 2002 00:55:56 -0000 1.1 +++ box_start.html 5 Nov 2002 22:28:29 -0000 1.2 @@ -1,4 +1,4 @@ -<TABLE border="0" cellspacing="0" cellpadding="0" align="center" width="<!--WIDTH-->"> +<TABLE border="0" cellspacing="0" cellpadding="0" align="center" <!--WIDTH-->> <TR> <TD width="31"><IMG src="<%--THEMEROOT--%>/images/box/top_left_pic.gif" width="31" height="24" alt="" border="0"></TD> <TD background="<%--THEMEROOT--%>/images/box/top_mid_back.gif"><IMG src="<%--THEMEROOT--%>/images/blank.gif" width="1" height="1" alt="" border="0"></TD> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:28:36
|
Update of /var/lib/cvs/bWF2/web/themes/blue-heart In directory apollo:/tmp/cvs-serv30165/blue-heart Modified Files: box_item.html box_start.html Log Message: minor fixes. html-snippets... Index: box_item.html =================================================================== RCS file: /var/lib/cvs/bWF2/web/themes/blue-heart/box_item.html,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- box_item.html 5 Nov 2002 00:54:56 -0000 1.1 +++ box_item.html 5 Nov 2002 22:28:28 -0000 1.2 @@ -2,7 +2,7 @@ <TD width="32" background="<%--THEMEROOT--%>/images/box/text_right_back.gif"><IMG src="<%--THEMEROOT--%>/images/blank.gif" width="1" height="1" alt="" border="0"></TD> </TR><TR> <TD width="31"><IMG src="<%--THEMEROOT--%>/images/box/item_left_pic.gif" width="31" height="27" alt="" border="0"></TD> -<TD width="100%" nowrap background="<%--THEMEROOT--%>/images/box/item_mid_back.gif"><B><!--TITLE--></B></TD> +<TD nowrap background="<%--THEMEROOT--%>/images/box/item_mid_back.gif"><B><!--TITLE--></B></TD> <TD width="32"><IMG src="<%--THEMEROOT--%>/images/box/item_right_pic.gif" width="32" height=27 alt="" border="0"></TD> </TR><TR> <TD width="31" background="<%--THEMEROOT--%>/images/box/text_left_back.gif"><IMG src="<%--THEMEROOT--%>/images/blank.gif" width="1" height="1" alt="" border="0"></TD> Index: box_start.html =================================================================== RCS file: /var/lib/cvs/bWF2/web/themes/blue-heart/box_start.html,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- box_start.html 5 Nov 2002 00:54:56 -0000 1.1 +++ box_start.html 5 Nov 2002 22:28:28 -0000 1.2 @@ -1,4 +1,4 @@ -<TABLE border="0" cellspacing="0" cellpadding="0" align="center" width="<!--WIDTH-->"> +<TABLE border="0" cellspacing="0" cellpadding="0" align="center" <!--WIDTH-->> <TR> <TD width="31"><IMG src="<%--THEMEROOT--%>/images/box/top_left_pic.gif" width="31" height="24" alt="" border="0"></TD> <TD background="<%--THEMEROOT--%>/images/box/top_mid_back.gif"><IMG src="<%--THEMEROOT--%>/images/blank.gif" width="1" height="1" alt="" border="0"></TD> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:28:04
|
Update of /var/lib/cvs/bWF2/web/themes/simple In directory apollo:/tmp/cvs-serv30114 Added Files: box_item.html box_start.html box_stop.html footer.html header.html Log Message: a simple theme. --- NEW FILE: box_item.html --- </TD> <TD bgcolor="#eeeeee"> </TD> </TR><TR> <TD bgcolor="#eeeeee">o</TD> <TD nowrap bgcolor="#eeeeee"><B><!--TITLE--></B></TD> <TD bgcolor="#eeeeee">o</TD> </TR><TR> <TD bgcolor="#eeeeee"> </TD> <TD> --- NEW FILE: box_start.html --- <TABLE border="0" cellspacing="0" cellpadding="0" align="center" <!--WIDTH-->> <TR> <TD bgcolor="#eeeeee">+</TD> <TD bgcolor="#eeeeee"><hr></TD> <TD bgcolor="#eeeeee">+</TD> </TR><TR> <TD bgcolor="#eeeeee"> </TD> <TD align="left"> --- NEW FILE: box_stop.html --- </TD> <TD bgcolor="#eeeeee"> </TD> </TR><TR> <TD bgcolor="#eeeeee">+</TD> <TD bgcolor="#eeeeee"><hr></TD> <TD bgcolor="#eeeeee">+</TD> </TR> </TABLE> --- NEW FILE: footer.html --- <hr> <font size="1">(C) by the bchat developer group</font> </body> </html> --- NEW FILE: header.html --- <html> <head> <title><!--TITLE--></title> </head> <body text="#000000" bgcolor="#cccccc" link="#555555"> |
From: Thomas J. <fa...@ap...> - 2002-11-05 22:27:47
|
Update of /var/lib/cvs/bWF2/web/themes/simple In directory apollo:/tmp/cvs-serv30074/simple Log Message: Directory /var/lib/cvs/bWF2/web/themes/simple added to the repository |
From: Thomas J. <fa...@ap...> - 2002-11-05 09:42:23
|
Update of /var/lib/cvs/bWF2/web/admin In directory apollo:/tmp/cvs-serv6579/admin Modified Files: index.jsp Log Message: it's getTheme, not getSkin Index: index.jsp =================================================================== RCS file: /var/lib/cvs/bWF2/web/admin/index.jsp,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- index.jsp 5 Nov 2002 00:44:50 -0000 1.1 +++ index.jsp 5 Nov 2002 09:42:12 -0000 1.2 @@ -27,7 +27,7 @@ } %> <i18n:bundle baseName="i18nResources" locale="<%=user.getLocale()%>"/> -<theme:select themeName="<%=user.getSkinName()%>"/> +<theme:select themeName="<%=user.getTheme()%>"/> <theme:header pageTitle="Admin Area"/> <center> <br><br> |
From: Thomas J. <fa...@ap...> - 2002-11-05 01:04:12
|
Update of /var/lib/cvs/bWF2 In directory apollo:/tmp/cvs-serv28710 Modified Files: config.fake Log Message: add relative url. that's it for tonight - sleep well ;) Index: config.fake =================================================================== RCS file: /var/lib/cvs/bWF2/config.fake,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- config.fake 30 Oct 2002 18:51:58 -0000 1.7 +++ config.fake 5 Nov 2002 01:04:04 -0000 1.8 @@ -11,3 +11,5 @@ mail.host=localhost mail.from=cha...@bi... + +web.url=/bWF2-fake |
From: Thomas J. <fa...@ap...> - 2002-11-05 01:02:26
|
Update of /var/lib/cvs/bWF2/src/taglibs/bWF2Theme In directory apollo:/tmp/cvs-serv28605/bWF2Theme Added Files: Box.java Footer.java Header.java Select.java Log Message: take one of a lot --- NEW FILE: Box.java --- package taglibs.bWF2Theme; import de.bchat.bwf2.bWF2Repository; import java.util.HashMap; import javax.servlet.jsp.*; import javax.servlet.jsp.tagext.*; import org.apache.log4j.Logger; public class Box extends BodyTagSupport { String width = ""; String part = ""; String title = ""; static Logger log = Logger.getLogger("bWF2Theme-Box"); public void setwidth(String width) { this.width = width; } public void setpart(String part) { this.part = part; } public void settitle(String title) { this.title = title; } public int doStartTag() throws JspException { HashMap tags = new HashMap(); tags.put("title",title); tags.put("width",width); try { pageContext.getOut().print(bWF2Repository.getTheme(Select.name).getParsedObject("box_"+part, tags)); } catch (Exception ex) { log.error("IO Problems", ex); } return SKIP_BODY; } } --- NEW FILE: Footer.java --- package taglibs.bWF2Theme; import de.bchat.bwf2.bWF2Repository; import javax.servlet.jsp.*; import javax.servlet.jsp.tagext.*; import org.apache.log4j.Logger; public class Footer extends BodyTagSupport { static Logger log = Logger.getLogger("bWF2Theme-Footer"); public int doStartTag() throws JspException { try { pageContext.getOut().print(bWF2Repository.getTheme(Select.name).getObject("footer")); } catch (Exception ex) { log.error("IO Problems", ex); } return SKIP_BODY; } } --- NEW FILE: Header.java --- package taglibs.bWF2Theme; import de.bchat.bwf2.bWF2Repository; import java.util.HashMap; import javax.servlet.jsp.*; import javax.servlet.jsp.tagext.*; import org.apache.log4j.Logger; public class Header extends BodyTagSupport { String title = ""; static Logger log = Logger.getLogger("bWF2Theme-Header"); public void setpageTitle(String title) { this.title = title; } public int doStartTag() throws JspException { HashMap tags = new HashMap(); tags.put("title",title); try { pageContext.getOut().print(bWF2Repository.getTheme(Select.name).getParsedObject("header", tags)); } catch (Exception ex) { log.error("IO Problems", ex); } return SKIP_BODY; } } --- NEW FILE: Select.java --- package taglibs.bWF2Theme; import javax.servlet.jsp.*; import javax.servlet.jsp.tagext.*; import org.apache.log4j.Logger; public class Select extends BodyTagSupport { static String name = "default"; static Logger log = Logger.getLogger("bWF2Theme-Select"); public void setthemeName(String name) { this.name = name; } public int doStartTag() throws JspException { log.debug("Set Theme " + name); return SKIP_BODY; } } |
From: Thomas J. <fa...@ap...> - 2002-11-05 01:01:06
|
Update of /var/lib/cvs/bWF2/src/taglibs/bWF2Theme In directory apollo:/tmp/cvs-serv28324/bWF2Theme Log Message: Directory /var/lib/cvs/bWF2/src/taglibs/bWF2Theme added to the repository |
From: Thomas J. <fa...@ap...> - 2002-11-05 01:00:52
|
Update of /var/lib/cvs/bWF2/src/taglibs In directory apollo:/tmp/cvs-serv28301/taglibs Log Message: Directory /var/lib/cvs/bWF2/src/taglibs added to the repository |
From: Thomas J. <fa...@ap...> - 2002-11-05 01:00:29
|
Update of /var/lib/cvs/bWF2/src/de/bchat/bwf2/theming In directory apollo:/tmp/cvs-serv28249/theming Added Files: bWF2Theme.java Log Message: added theme companion methods. get themes, parse the special theme.properties file, flush config... pretty weird. added bWF2Theme --- NEW FILE: bWF2Theme.java --- package de.bchat.bwf2.theming; import java.util.HashMap; import java.util.Iterator; import java.io.File; import java.io.FileReader; import java.io.BufferedReader; import java.io.FileNotFoundException; import java.io.IOException; import de.bchat.bwf2.bWF2Repository; import org.apache.log4j.Logger; public class bWF2Theme { private static Logger log = Logger.getLogger("bWF2Theme"); private String name = null; private String themeroot = ""; private HashMap objects = new HashMap(); private HashMap metainf = new HashMap(); public bWF2Theme(String name, HashMap files, HashMap metainf) { if(name == null) { log.error("Tried to create new theme, but the name was null!"); throw new NullPointerException("The name must not be null!"); } this.name = name; themeroot = bWF2Repository.getProperty("bchat.themes.URL","") + "/" + bWF2Repository.getProperty("bchat.themes.DIRECTORY","themes") + "/" + name; log.debug("set themeroot to " + themeroot); this.metainf = metainf; readFiles(files); } private void readFiles(HashMap files) { Iterator fit = files.keySet().iterator(); while(fit.hasNext()) { String object = (String)fit.next(); String filename = (String)files.get(object); String abs_filename = bWF2Repository.getWebPath() + File.separator + bWF2Repository.getProperty("bchat.themes.DIRECTORY","themes") + File.separator + name + File.separator + filename; try { StringBuffer content = new StringBuffer(); String tmp = ""; BufferedReader in = new BufferedReader(new FileReader(new File(abs_filename))); while((tmp = in.readLine()) != null) { content.append(tmp); } objects.put(object, (content.toString().replaceAll("<%--THEMEROOT--%>",themeroot))); } catch(FileNotFoundException fnfe) { log.error("File not found!",fnfe); } catch(IOException ioex) { log.error("I/O Problem: ",ioex); } } } public String getObject(String name) { return (String)objects.get(name); } public String getParsedObject(String name, HashMap tags) { String object = (String)objects.get(name); Iterator tagit = tags.keySet().iterator(); while(tagit.hasNext()) { String tag = (String)tagit.next(); String value = (String)tags.get(tag); object = object.replaceAll("<!--"+(tag.toUpperCase())+"-->",value); } return object; } } |
From: Thomas J. <fa...@ap...> - 2002-11-05 01:00:29
|
Update of /var/lib/cvs/bWF2/src/de/bchat/bwf2 In directory apollo:/tmp/cvs-serv28249 Modified Files: bWF2Repository.java Log Message: added theme companion methods. get themes, parse the special theme.properties file, flush config... pretty weird. added bWF2Theme Index: bWF2Repository.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/de/bchat/bwf2/bWF2Repository.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- bWF2Repository.java 27 Oct 2002 04:17:41 -0000 1.6 +++ bWF2Repository.java 5 Nov 2002 01:00:21 -0000 1.7 @@ -3,14 +3,20 @@ import java.util.HashMap; import java.util.Locale; import java.util.ResourceBundle; +import java.util.Enumeration; +import java.util.Iterator; import java.util.regex.Pattern; +import java.lang.reflect.Array; + import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.IOException; import de.bchat.common.auth.Gpw; +import de.bchat.bwf2.theming.bWF2Theme; +import de.bchat.database.bchatDatabase; import org.apache.log4j.Logger; @@ -26,10 +32,14 @@ private static Gpw gpw = new Gpw(); private static String mContextPath; + private static String mWebPath; public static java.util.Properties mConfiguration = null; public static java.util.Properties mRegExStrings = null; + public static java.util.Properties mThemeProperties=null; public static HashMap mCompiledRegExps = new HashMap(); + public static HashMap mThemes = new HashMap(); + public static String[] mThemeNames = null; private static Logger log = Logger.getLogger("bWF2Repository"); @@ -48,13 +58,16 @@ try { File prop = new File(properties); mContextPath = prop.getParent(); + File web = new File(mContextPath); + mWebPath = web.getParent(); log.debug("Setting mContextPath to " + mContextPath); + log.debug("Setting mWebPath to " + mWebPath); mConfiguration.load(new FileInputStream(prop)); } catch(IOException iox) { log.error("Could not read properties", iox); throw iox; } - } + } public static Locale getDefaultLocale() { if(mDefaultLocale == null) { @@ -101,7 +114,7 @@ public static String getProperty(String key, String def) { if(mConfiguration == null) { try { - File info = new File(System.getProperties().getProperty("bWF2.properties", "bWF2.properties")); + File info = new File( mContextPath + File.separator + "bWF2.properties"); log.debug("Loading properties from file " + info.getAbsoluteFile()); FileInputStream content = new FileInputStream(info); mConfiguration = new java.util.Properties(); @@ -150,7 +163,9 @@ if(mRegExStrings == null) { try { getProperty("load","load"); //ensure the properties are loaded - File info = new File(mContextPath + File.separator + getProperty("bchat.regexps.DEFINITION_FILE", "regularExpressions.properties")); + File info = new File(mContextPath + + File.separator + + getProperty("bchat.regexps.DEFINITION_FILE", "regularExpressions.properties")); log.debug("Loading regular expressions from file " + info.getAbsoluteFile()); FileInputStream content = new FileInputStream(info); mRegExStrings = new java.util.Properties(); @@ -178,9 +193,106 @@ return mContextPath; } + public static String getWebPath() { + return mWebPath; + } + public static String genPassword() { String pwdLenS = (String)getProperty("bchat.common.auth.PWDLEN","8"); int pwdLen = (Integer.valueOf(pwdLenS)).intValue(); return gpw.generate(pwdLen); } + + public static bWF2Theme getTheme(String name) { + if(mThemes.get(name) == null) { + if(mThemeProperties == null) { + try { + getProperty("load","load"); + File info = new File(mContextPath + + File.separator + + getProperty("bchat.themes.DEFINITION_FILE", "themes.properties")); + log.debug("Loading theme information from file " + + getProperty("bchat.themes.DEFINITION_FILE", "themes.properties")); + FileInputStream content = new FileInputStream(info); + mThemeProperties= new java.util.Properties(); + mThemeProperties.load(content); + + mThemes = parseThemes(); + } catch(java.io.FileNotFoundException fnfe) { + log.error("configuration could not be loaded - file not found", fnfe); + mConfiguration = null; + } catch(java.io.IOException ioe) { + log.error("configuration could not be loaded - ioexception", ioe); + mConfiguration = null; + } + } + + + } + return (bWF2Theme)mThemes.get(name); + } + + private static HashMap parseThemes() { + HashMap themes = new HashMap(); + + Enumeration tenu = mThemeProperties.propertyNames(); + while(tenu.hasMoreElements()) { + String curkey = (String) tenu.nextElement(); + String cvalue = mThemeProperties.getProperty(curkey); + if(cvalue == null || cvalue.trim().equals("")) { //a new theme name + log.debug("found theme: " + curkey); + HashMap files = new HashMap(); + HashMap meta= new HashMap(); + + Enumeration eenu = mThemeProperties.propertyNames(); + while(eenu.hasMoreElements()) { + String ekey = (String) eenu.nextElement(); + if(ekey.startsWith(curkey+".")) { + if(ekey.startsWith(curkey+".file.")) { + files.put(ekey.substring((curkey+".file.").length(), ekey.length()), + mThemeProperties.getProperty(ekey)); + } else { + meta.put(ekey.substring(curkey.length()+1,ekey.length()), + mThemeProperties.getProperty(ekey)) ; + } + } + } + themes.put(curkey, new bWF2Theme(curkey, files, meta)); + } + } + + return themes; + } + + public static String[] getThemes() { + getTheme("make-sure-themes-are-loaded"); + + if(mThemeNames == null) { + mThemeNames = new String[mThemes.size()]; + int i=0; + Iterator tit = mThemes.keySet().iterator(); + while(tit.hasNext()) { + mThemeNames[i++] = (String)tit.next(); + } + } + + return mThemeNames; + } + + public static synchronized void flushConfigs() { + //Regular Expressions + mCompiledRegExps = new HashMap(); + mRegExStrings = null; + //Themes + mThemeNames = null; + mThemes = new HashMap(); + mThemeProperties = null; + //locale + mDefaultLocale = null; + //general configs + mConfiguration = null; + } + } + + |
From: Thomas J. <fa...@ap...> - 2002-11-05 00:58:24
|
Update of /var/lib/cvs/bWF2/src/de/bchat/database In directory apollo:/tmp/cvs-serv28111 Modified Files: bchatDatabase.java Log Message: the fields in the db have changed a bit. ICQ->IM, skin_defs is gone, skin -> theme, now string, not int. Index: bchatDatabase.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/de/bchat/database/bchatDatabase.java,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- bchatDatabase.java 4 Nov 2002 23:48:43 -0000 1.13 +++ bchatDatabase.java 5 Nov 2002 00:58:17 -0000 1.14 @@ -76,10 +76,9 @@ try { Statement stmt = con.createStatement(); - ResultSet rs = stmt.executeQuery("SELECT * FROM udata LEFT JOIN skin_defs ON udata.skin = skin_defs.ID " + - "WHERE udata.ID='" + user.getUserID() + "'"); + ResultSet rs = stmt.executeQuery("SELECT * FROM udata WHERE udata.ID='" + user.getUserID() + "'"); if(rs.next()) { - user.setIM(rs.getString("ICQ")); + user.setIM(rs.getString("IM")); user.setAlias(rs.getString("Alias")); user.setBanned(rs.getBoolean("banned")); user.setEmail(rs.getString("Email")); @@ -94,8 +93,7 @@ user.setPublic(rs.getBoolean("pub")); user.setRealName(rs.getString("realname")); user.setAdmin(rs.getBoolean("right_table")); - user.setSkin(rs.getInt("skin")); - user.setSkinName(rs.getString("name")); + user.setTheme(rs.getString("theme")); user.setWhisperWindow(rs.getBoolean("whisperwin")); if (rs.getString("locale") != null) { user.setLocale(new Locale(rs.getString("locale"),"")); @@ -180,7 +178,7 @@ boolean ret = false; String upd = "UPDATE udata SET " + - " icq='" + user.getIM() + "', " + + " im='" + user.getIM() + "', " + " alias='" + user.getAlias() + "', " + " banned='" + ( user.getBanned() ? "1" : "0" ) + "', " + " email='" + user.getEmail() + "', " + @@ -194,13 +192,12 @@ " logout_text='" + user.getLogoutText() + "', " + " pub='" + ( user.getPublic() ? "yes" : "no" ) + "', " + " realname='" + user.getRealName() + "', " + + " theme='" + user.getTheme() + "', " + " whisperwin='" + ( user.getWhisperWindow() ? "1" : "0" ) + "', " + " right_table='" + ( user.getAdmin() ? "1" : "0" ) + "', " + " locale='" + user.getLocale().toString() +"'"+ " WHERE ID = '" + user.getUserID() + "'"; - - //user.setSkin(rs.getString("skin")); try { Statement stmt = con.createStatement(); |
From: Thomas J. <fa...@ap...> - 2002-11-05 00:57:40
|
Update of /var/lib/cvs/bWF2/src/de/bchat/common In directory apollo:/tmp/cvs-serv28056 Modified Files: bchatUser.java Log Message: a skin is now called a theme. Index: bchatUser.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/de/bchat/common/bchatUser.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- bchatUser.java 2 Nov 2002 07:00:19 -0000 1.5 +++ bchatUser.java 5 Nov 2002 00:57:31 -0000 1.6 @@ -268,12 +268,12 @@ } } - public String getSkin() { - return (userData.get("skin") != null) ? (String)userData.get("skin") : ""; + public String getTheme() { + return (userData.get("theme") != null) ? (String)userData.get("theme") : "default"; } - public void setSkin(String skin) { - userData.put("skin", skin); + public void setTheme(String theme) { + userData.put("theme", theme); } public void setWhisperWindow(boolean whisperwin) { |
From: Thomas J. <fa...@ap...> - 2002-11-05 00:56:46
|
Update of /var/lib/cvs/bWF2/src/servlets In directory apollo:/tmp/cvs-serv27924 Modified Files: EditUserData.java Log Message: honor skin->theme change Index: EditUserData.java =================================================================== RCS file: /var/lib/cvs/bWF2/src/servlets/EditUserData.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- EditUserData.java 2 Nov 2002 06:59:40 -0000 1.6 +++ EditUserData.java 5 Nov 2002 00:56:39 -0000 1.7 @@ -65,6 +65,7 @@ String new_logouttext = request.getParameter("new_logouttext"); String new_realname = request.getParameter("new_realname"); String new_locale_string = request.getParameter("new_locale"); + String new_theme = request.getParameter("new_theme"); boolean new_alias_locked = false, new_banned = false, new_granted = false, new_public = false, new_haxor = false, new_whisperwin = false, @@ -137,6 +138,7 @@ userToEdit.setPublic(new_public); userToEdit.setPublicEmail(new_public_email); userToEdit.setRealName(new_realname); + userToEdit.setTheme(new_theme); userToEdit.setWhisperWindow(new_whisperwin); if(new_locale != null) { userToEdit.setLocale(new_locale); |