Upstream r1794: Yet another Replacement of some deprecated classes and method invocations by supported API

git-svn-id: https://svn.libreccm.org/ccm/trunk@72 8810af33-2d31-482b-a856-94f89814c4df
master
pb 2009-02-07 08:55:51 +00:00
parent c88891c8ba
commit 743ff9b5d4
2 changed files with 6 additions and 4 deletions

View File

@ -24,7 +24,7 @@ import java.net.URLDecoder;
import org.apache.log4j.Category; import org.apache.log4j.Category;
import com.arsdigita.bebop.ActionLink; import com.arsdigita.bebop.ActionLink;
import com.arsdigita.bebop.BebopMapDispatcher; import com.arsdigita.bebop.page.BebopMapDispatcher;
import com.arsdigita.bebop.Label; import com.arsdigita.bebop.Label;
import com.arsdigita.bebop.Page; import com.arsdigita.bebop.Page;
import com.arsdigita.bebop.PageState; import com.arsdigita.bebop.PageState;
@ -162,7 +162,8 @@ public class DMDispatcher extends BebopMapDispatcher implements DMConstants {
} }
protected void buildContextBar() { protected void buildContextBar() {
FileDimensionalNavbar navbar = new FileDimensionalNavbar(new RequestLocal() { FileDimensionalNavbar navbar = new FileDimensionalNavbar(
new RequestLocal() {
protected Object initialValue(PageState state) { protected Object initialValue(PageState state) {
BigDecimal id = (BigDecimal) state.getValue(fileIDParam); BigDecimal id = (BigDecimal) state.getValue(fileIDParam);
return new Document(id); return new Document(id);
@ -269,7 +270,8 @@ public class DMDispatcher extends BebopMapDispatcher implements DMConstants {
BigDecimal id = new BigDecimal(str); BigDecimal id = new BigDecimal(str);
s_log.debug("requesting file for id: "+str); s_log.debug("requesting file for id: "+str);
Document doc = new Document(id); Document doc = new Document(id);
resp.setHeader("Content-Disposition", "attachment; filename=" + URLDecoder.decode(doc.getName())); resp.setHeader("Content-Disposition", "attachment; filename=" +
URLDecoder.decode(doc.getName()));
doc.assertPrivilege(PrivilegeDescriptor.READ); doc.assertPrivilege(PrivilegeDescriptor.READ);
// if the user has requested an earlier revision, get // if the user has requested an earlier revision, get

View File

@ -24,7 +24,7 @@ import java.math.BigDecimal;
import org.apache.log4j.Category; import org.apache.log4j.Category;
import com.arsdigita.bebop.ActionLink; import com.arsdigita.bebop.ActionLink;
import com.arsdigita.bebop.BebopMapDispatcher; import com.arsdigita.bebop.page.BebopMapDispatcher;
import com.arsdigita.bebop.Label; import com.arsdigita.bebop.Label;
import com.arsdigita.bebop.Page; import com.arsdigita.bebop.Page;
import com.arsdigita.bebop.PageState; import com.arsdigita.bebop.PageState;