import java.util.UUID;
import java.util.concurrent.Callable;
+import javax.inject.Inject;
import javax.security.auth.Subject;
import javax.security.auth.login.LoginContext;
import javax.security.auth.login.LoginException;
import org.argeo.api.cms.CmsAuth;
+import org.argeo.api.cms.CmsContext;
import org.argeo.api.cms.CmsLog;
import org.argeo.api.cms.ux.CmsImageManager;
import org.argeo.api.cms.ux.CmsView;
import org.argeo.api.cms.ux.UxContext;
-import org.argeo.cms.auth.CurrentUser;
+import org.argeo.cms.CurrentUser;
import org.argeo.cms.swt.CmsSwtUtils;
import org.argeo.cms.swt.SimpleSwtUxContext;
import org.argeo.cms.swt.acr.AcrSwtImageManager;
public class CmsLoginLifecycle implements CmsView {
private final static CmsLog log = CmsLog.getLog(CmsLoginLifecycle.class);
+ @Inject
+ private CmsContext cmsContext;
+
private UxContext uxContext;
private CmsImageManager imageManager;
Subject subject = Subject.getSubject(AccessController.getContext());
Display display = Display.getCurrent();
// UiContext.setData(CmsView.KEY, this);
- // FIXME get CMS context
- CmsLoginShell loginShell = new CmsLoginShell(this, null);
+ CmsLoginShell loginShell = new CmsLoginShell(this, cmsContext);
CmsSwtUtils.registerCmsView(loginShell.getShell(), this);
loginShell.setSubject(subject);
try {
public void exception(Throwable e) {
String msg = "Unexpected exception in Eclipse 4 RAP";
log.error(msg, e);
- CmsFeedback.show(msg, e);
+ CmsFeedback.error(msg, e);
}
@Override