cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tomek...@apache.org
Subject svn commit: r1023578 - /cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/
Date Sun, 17 Oct 2010 20:55:22 GMT
Author: tomekopo
Date: Sun Oct 17 20:55:21 2010
New Revision: 1023578

URL: http://svn.apache.org/viewvc?rev=1023578&view=rev
Log:
Added new user interface elements realted with filtering

Added:
    cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.java
    cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.ui.xml
    cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialogImpl.java
Modified:
    cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseView.ui.xml
    cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseViewImpl.java

Modified: cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseView.ui.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseView.ui.xml?rev=1023578&r1=1023577&r2=1023578&view=diff
==============================================================================
--- cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseView.ui.xml
(original)
+++ cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseView.ui.xml
Sun Oct 17 20:55:21 2010
@@ -38,26 +38,44 @@
 				<g:center>
 					<g:SplitLayoutPanel>
 						<g:west size='192'>
-							<g:DockLayoutPanel unit="EM"
-                                               styleName="{res.css.browserTabSubscriptionsSideBar}">
-                                <g:north size="2.2">
-                                    <g:HTMLPanel>
-                                        <div class="{res.css.browserTabSubscriptionsHeader}">
-                                            Endpoints
+                            <g:StackLayoutPanel unit='EM'>
+                                <g:stack>
+                                    <g:header size='3'>
+                                        <div>
+                                            <div/>
+                                            Explore
                                         </div>
-                                    </g:HTMLPanel>
-                                </g:north>
-								<g:center>
-                                    <logbrowser:SubscriptionTable ui:field='subscriptionTable'
-                                                                  styleName='{res.css.browserTabEntrySelectableTable}'/>
-								</g:center>
-								<g:south size="2">
-									<g:Hyperlink ui:field="manageSubscriptionsHyperlink"
-                                                 addStyleNames="{res.css.browserTabManageSubscriptionsButton}">
-                                        Manage endpoints &#187;
-                                    </g:Hyperlink>
-								</g:south>
-							</g:DockLayoutPanel>
+                                    </g:header>
+
+                                    <g:VerticalPanel width="100%">
+                                        <g:Label>Tasks</g:Label>
+                                        <g:Hyperlink ui:field="manageSubscriptionsHyperlink">
+                                                Manage endpoints
+                                        </g:Hyperlink>
+                                        <g:Label>Endpoints</g:Label>
+                                        <logbrowser:SubscriptionTable ui:field='exploreSubscriptionTable'
+                                                                      styleName='{res.css.browserTabEntrySelectableTable}'/>
+                                    </g:VerticalPanel>
+                                </g:stack>
+                                <g:stack>
+                                    <g:header size='3'>
+                                        <div>
+                                            <div/>
+                                            Filter
+                                        </div>
+                                    </g:header>
+
+                                    <g:VerticalPanel width="100%">
+                                        <g:Label>Tasks</g:Label>
+                                        <g:Hyperlink ui:field="editCriteriaHyperlink">
+                                                Edit criteria
+                                        </g:Hyperlink>
+                                        <g:Label>Endpoints</g:Label>
+                                        <logbrowser:SubscriptionTable ui:field='filterSubscriptionTable'
+                                                                          styleName='{res.css.browserTabEntrySelectableTable}'/>
+                                    </g:VerticalPanel>
+                                </g:stack>
+                            </g:StackLayoutPanel>
 						</g:west>
 
 						<g:north size='200'>

Modified: cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseViewImpl.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseViewImpl.java?rev=1023578&r1=1023577&r2=1023578&view=diff
==============================================================================
--- cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseViewImpl.java
(original)
+++ cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/BrowseViewImpl.java
Sun Oct 17 20:55:21 2010
@@ -38,16 +38,15 @@ import com.google.gwt.user.client.ui.HTM
 import com.google.gwt.user.client.ui.HasHorizontalAlignment;
 import com.google.gwt.user.client.ui.Widget;
 import com.google.inject.Inject;
-
 import org.apache.cxf.management.web.logging.logbrowser.client.service.browser.Entry;
 import org.apache.cxf.management.web.logging.logbrowser.client.service.browser.Links;
 import org.apache.cxf.management.web.logging.logbrowser.client.service.settings.Subscription;
 import org.apache.cxf.management.web.logging.logbrowser.client.ui.resources.LogBrowserConstans;
 
 import static org.apache.cxf.management.web.logging.logbrowser.client.ui.browser
-    .SelectableTable.SelectRowHandler;
+        .SelectableTable.SelectRowHandler;
 import static org.apache.cxf.management.web.logging.logbrowser.client.ui.browser
-    .SubscriptionTable.ColumnDefinition;
+        .SubscriptionTable.ColumnDefinition;
 
 public class BrowseViewImpl extends Composite implements BrowseView {
     private static final DateTimeFormat DT_FORMATTER =
@@ -59,7 +58,10 @@ public class BrowseViewImpl extends Comp
     private static final BrowseViewUiBinder UI_BINDER = GWT.create(BrowseViewUiBinder.class);
 
     @UiField @Nonnull
-    SubscriptionTable subscriptionTable;
+    SubscriptionTable exploreSubscriptionTable;
+
+    @UiField @Nonnull
+    SubscriptionTable filterSubscriptionTable;
 
     @UiField @Nonnull
     FlexTable entryTableHeader;
@@ -88,12 +90,15 @@ public class BrowseViewImpl extends Comp
         initNavigationLinks();
         initEntryTableHeader();
 
-        initSubscriptionTable();
+        initSubscriptionTable(exploreSubscriptionTable);
+        initSubscriptionTable(filterSubscriptionTable);
+        
         initEntryTable();
     }
 
     public void setSubscriptions(@Nonnull final List<Subscription> subscriptions) {
-        subscriptionTable.setData(subscriptions);
+        exploreSubscriptionTable.setData(subscriptions);
+        filterSubscriptionTable.setData(subscriptions);
     }
 
     public void setEntries(@Nonnull final List<Entry> entries) {
@@ -135,6 +140,13 @@ public class BrowseViewImpl extends Comp
         assert presenter != null;
         presenter.onSignOutButtonClicked();
     }
+    
+    @UiHandler("editCriteriaHyperlink")
+    void onEditCriteriaHyperlinkClicked(@Nonnull final ClickEvent event) {
+
+        //TODO temporary solution
+        new EditCriteriaDialogImpl().show();    
+    }
 
     @UiHandler("manageSubscriptionsHyperlink")
     void onManageSubscriptionsHyperlinkClicked(@Nonnull final ClickEvent event) {
@@ -206,7 +218,7 @@ public class BrowseViewImpl extends Comp
         entryTableHeader.getCellFormatter().setHorizontalAlignment(0, 3, HasHorizontalAlignment.ALIGN_RIGHT);
     }
 
-    private void initSubscriptionTable() {
+    private void initSubscriptionTable(@Nonnull final SubscriptionTable table) {
         List<ColumnDefinition<Subscription>> columnDefinitions =
             new ArrayList<ColumnDefinition<Subscription>>();
 
@@ -221,9 +233,9 @@ public class BrowseViewImpl extends Comp
             }
         });
 
-        subscriptionTable.setColumnDefinitions(columnDefinitions);
+        table.setColumnDefinitions(columnDefinitions);
 
-        subscriptionTable.addSelectRowHandler(new SelectRowHandler() {
+        table.addSelectRowHandler(new SelectRowHandler() {
 
             public void onSelectRow(int row) {
                 assert presenter != null;

Added: cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.java?rev=1023578&view=auto
==============================================================================
--- cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.java
(added)
+++ cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.java
Sun Oct 17 20:55:21 2010
@@ -0,0 +1,23 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.management.web.logging.logbrowser.client.ui.browser;
+
+public interface EditCriteriaDialog {
+}

Added: cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.ui.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.ui.xml?rev=1023578&view=auto
==============================================================================
--- cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.ui.xml
(added)
+++ cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialog.ui.xml
Sun Oct 17 20:55:21 2010
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+  -->
+
+<ui:UiBinder xmlns:ui='urn:ui:com.google.gwt.uibinder'
+	xmlns:g='urn:import:com.google.gwt.user.client.ui'
+    xmlns:dp="urn:import:com.google.gwt.user.datepicker.client" >
+
+    <ui:with field='res'
+             type='org.apache.cxf.management.web.logging.logbrowser.client.ui.resources.LogBrowserResources'/>
+
+	<g:HTMLPanel>
+		<table cellspacing="6">
+			<tr>
+				<td>
+					<g:Label>From:</g:Label>
+				</td>
+                <td>
+					<dp:DateBox></dp:DateBox>
+				</td>
+
+				<td>
+					<g:Label>To:</g:Label>
+				</td>
+                <td>
+					<dp:DateBox></dp:DateBox>
+				</td>
+			</tr>
+            <tr>
+                <td>
+                    <g:Label>Levels:</g:Label>
+                </td>
+                <td>
+                    <g:VerticalPanel>
+                        <g:CheckBox>DEBUG</g:CheckBox>
+                        <g:CheckBox>WARN</g:CheckBox>
+                        <g:CheckBox>INFO</g:CheckBox>
+                        <g:CheckBox>ERROR</g:CheckBox>
+                    </g:VerticalPanel>
+                </td>
+            </tr>
+		</table>
+		<g:FlowPanel addStyleNames="{res.css.editFeedDialogButtons}">
+			<g:Button ui:field="cancelButton">
+                Cancel
+            </g:Button>
+			<g:Button ui:field="saveButton" addStyleNames="{res.css.editFeedDialogAddButton}">
+                Save
+			</g:Button>
+		</g:FlowPanel>
+
+	</g:HTMLPanel>
+
+</ui:UiBinder>

Added: cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialogImpl.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialogImpl.java?rev=1023578&view=auto
==============================================================================
--- cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialogImpl.java
(added)
+++ cxf/sandbox/logbrowser/rt/management-web/src/main/java/org/apache/cxf/management/web/logging/logbrowser/client/ui/browser/EditCriteriaDialogImpl.java
Sun Oct 17 20:55:21 2010
@@ -0,0 +1,59 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.management.web.logging.logbrowser.client.ui.browser;
+
+import javax.annotation.Nonnull;
+
+import com.google.gwt.core.client.GWT;
+import com.google.gwt.uibinder.client.UiBinder;
+import com.google.gwt.uibinder.client.UiTemplate;
+import com.google.gwt.user.client.ui.Composite;
+import com.google.gwt.user.client.ui.DialogBox;
+import com.google.gwt.user.client.ui.Widget;
+
+public class EditCriteriaDialogImpl extends DialogBox implements EditCriteriaDialog {
+
+    @Nonnull
+    private Form form;
+
+    public EditCriteriaDialogImpl() {
+
+        //TODO temporary solution
+        form = new Form();
+        setGlassEnabled(true);
+        setAnimationEnabled(false);
+        setAutoHideEnabled(true);
+        setText("Edit criteria");
+        setWidget(form);
+        center();
+    }
+
+    protected static class Form extends Composite {
+
+        @UiTemplate("EditCriteriaDialog.ui.xml")
+        interface FormViewUiBinder extends UiBinder<Widget, Form> { }
+
+        private static final FormViewUiBinder UI_BINDER = GWT.create(FormViewUiBinder.class);
+
+        public Form() {
+            initWidget(UI_BINDER.createAndBindUi(this));
+        }
+    }
+}
\ No newline at end of file



Mime
View raw message