Update of /cvsroot/roller/roller/src/org/roller/presentation/weblog/actions
In directory
sc8-pr-cvs1:/tmp/cvs-serv3355/src/org/roller/presentation/weblog/actions
Modified Files:
WeblogEntryFormAction.java
Log Message:
Make pinging weblogs.com optional (checkbox). Defaults to checked for new
posts, not checked for existing posts.
Index: WeblogEntryFormAction.java
===================================================================
RCS file:
/cvsroot/roller/roller/src/org/roller/presentation/weblog/actions/WeblogEntryFormAction.java,v
retrieving revision 1.34
retrieving revision 1.35
diff -C2 -d -r1.34 -r1.35
*** WeblogEntryFormAction.java 7 Jun 2003 04:19:50 -0000 1.34
--- WeblogEntryFormAction.java 9 Jun 2003 02:43:36 -0000 1.35
***************
*** 75,87 ****
// entry has not already been saved by the request, then
// load weblog entry data into the form for editing.
WeblogEntryData wd = rreq.getWeblogEntry();
if ( wd!=null && request.getAttribute("saved")==null )
{
- WeblogEntryFormEx wf = (WeblogEntryFormEx)actionForm;
wf.setData(wd);
}
else
{
actionForm.reset(mapping,request);
}
--- 75,92 ----
// entry has not already been saved by the request, then
// load weblog entry data into the form for editing.
+ // new posts default Ping Weblogs.com = checked
+ // old posts default it to false
WeblogEntryData wd = rreq.getWeblogEntry();
+ WeblogEntryFormEx wf = (WeblogEntryFormEx)actionForm;
if ( wd!=null && request.getAttribute("saved")==null )
{
wf.setData(wd);
+ wf.setSendWeblogsPing(Boolean.FALSE);
}
else
{
actionForm.reset(mapping,request);
+
+ wf.setSendWeblogsPing(Boolean.TRUE);
}
***************
*** 202,207 ****
// send a ping to Weblogs.com
! boolean pingWeblogsCom = true;
! if (pingWeblogsCom)
{
String url =
RollerContext.getRollerContext(request).createEntryPermalink(entry,request,true);
--- 207,212 ----
// send a ping to Weblogs.com
! if (wf.getSendWeblogsPing() != null &&
! wf.getSendWeblogsPing().booleanValue())
{
String url =
RollerContext.getRollerContext(request).createEntryPermalink(entry,request,true);
-------------------------------------------------------
This SF.net email is sponsored by: Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
|