You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ah...@apache.org on 2013/02/01 21:46:41 UTC
svn commit: r1441623 - in
/flex/asjs/branches/develop/frameworks/as/src/org/apache/flex: core/
html/staticControls/beads/ html/staticControls/beads/models/
html/staticControls/supportClasses/
Author: aharui
Date: Fri Feb 1 20:46:40 2013
New Revision: 1441623
URL: http://svn.apache.org/viewvc?rev=1441623&view=rev
Log:
A Border
Added:
flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/core/IBorderModel.as (with props)
flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/SingleLineBorderBead.as (with props)
flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/models/SingleLineBorderModel.as (with props)
flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/supportClasses/Border.as (with props)
Added: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/core/IBorderModel.as
URL: http://svn.apache.org/viewvc/flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/core/IBorderModel.as?rev=1441623&view=auto
==============================================================================
--- flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/core/IBorderModel.as (added)
+++ flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/core/IBorderModel.as Fri Feb 1 20:46:40 2013
@@ -0,0 +1,27 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+// 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.flex.core
+{
+ import flash.geom.Rectangle;
+
+ public interface IBorderModel extends IBead, IBeadModel
+ {
+ function get offsets():Rectangle;
+ }
+}
\ No newline at end of file
Propchange: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/core/IBorderModel.as
------------------------------------------------------------------------------
svn:eol-style = native
Added: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/SingleLineBorderBead.as
URL: http://svn.apache.org/viewvc/flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/SingleLineBorderBead.as?rev=1441623&view=auto
==============================================================================
--- flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/SingleLineBorderBead.as (added)
+++ flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/SingleLineBorderBead.as Fri Feb 1 20:46:40 2013
@@ -0,0 +1,61 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+// 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.flex.html.staticControls.beads
+{
+ import flash.display.Graphics;
+ import flash.events.Event;
+ import flash.events.IEventDispatcher;
+
+ import org.apache.flex.core.IBead;
+ import org.apache.flex.core.IStrand;
+ import org.apache.flex.core.UIBase;
+
+ public class SingleLineBorderBead implements IBead
+ {
+ public function SingleLineBorderBead()
+ {
+ }
+
+ private var _strand:IStrand;
+
+ public function get strand():IStrand
+ {
+ return _strand;
+ }
+ public function set strand(value:IStrand):void
+ {
+ _strand = value;
+ IEventDispatcher(value).addEventListener("heightChanged", changeHandler);
+ IEventDispatcher(value).addEventListener("widthChanged", changeHandler);
+ }
+
+ private function changeHandler(event:Event):void
+ {
+ var host:UIBase = UIBase(_strand);
+ var g:Graphics = host.graphics;
+ var w:Number = host.width;
+ var h:Number = host.height;
+ g.clear();
+ g.beginFill(0);
+ g.drawRect(0, 0, w, h);
+ g.drawRect(1, 1, w-2, h-2);
+ g.endFill();
+ }
+ }
+}
\ No newline at end of file
Propchange: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/SingleLineBorderBead.as
------------------------------------------------------------------------------
svn:eol-style = native
Added: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/models/SingleLineBorderModel.as
URL: http://svn.apache.org/viewvc/flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/models/SingleLineBorderModel.as?rev=1441623&view=auto
==============================================================================
--- flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/models/SingleLineBorderModel.as (added)
+++ flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/models/SingleLineBorderModel.as Fri Feb 1 20:46:40 2013
@@ -0,0 +1,50 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+// 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.flex.html.staticControls.beads.models
+{
+ import flash.events.Event;
+ import flash.events.EventDispatcher;
+ import flash.geom.Rectangle;
+
+ import org.apache.flex.core.IBead;
+ import org.apache.flex.core.IBorderModel;
+ import org.apache.flex.core.IStrand;
+
+ public class SingleLineBorderModel extends EventDispatcher implements IBead, IBorderModel
+ {
+ public function SingleLineBorderModel()
+ {
+ }
+
+ private var _strand:IStrand;
+
+ public function set strand(value:IStrand):void
+ {
+ _strand = value;
+ }
+
+ static private var rect:Rectangle = new Rectangle(1, 1, 1, 1);
+
+ public function get offsets():Rectangle
+ {
+ return rect;
+ }
+
+ }
+}
\ No newline at end of file
Propchange: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/models/SingleLineBorderModel.as
------------------------------------------------------------------------------
svn:eol-style = native
Added: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/supportClasses/Border.as
URL: http://svn.apache.org/viewvc/flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/supportClasses/Border.as?rev=1441623&view=auto
==============================================================================
--- flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/supportClasses/Border.as (added)
+++ flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/supportClasses/Border.as Fri Feb 1 20:46:40 2013
@@ -0,0 +1,31 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+// 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.flex.html.staticControls.supportClasses
+{
+ import org.apache.flex.core.UIBase;
+
+ public class Border extends UIBase
+ {
+ public function Border()
+ {
+ super();
+ }
+
+ }
+}
\ No newline at end of file
Propchange: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/supportClasses/Border.as
------------------------------------------------------------------------------
svn:eol-style = native