メイン とにかくFLASH【FLASHに関して全般】 フォームアプリ作成ノウハウ | 投稿するにはまず登録を |
フラット表示 | 前のトピック | 次のトピック |
投稿者 | スレッド |
---|---|
flower | Åê¹ÆNo.11369 投稿日時: 2004-10-8 13:19 |
新米 居住地: 投稿: 5
使用環境:
|
Re: フォームアプリ作成ノウハウ 関さんありがとうございました。
Rendererのソースなのですが修正してこのようにしました。 import mx.core.UIComponent import mx.controls.ComboBox class ComboBoxRenderer extends UIComponent { var Combo : MovieClip; var listOwner : MovieClip; // the reference we receive to the list var getCellIndex : Function; // the function we receive from the list var getDataLabel : Function; // the function we receive from the list var cards2 = [ {label:"test1", data:1}, {label:"test2", data:2}, {label:"test3", data:3} ]; function ComboBoxCellRenderer() { } function createChildren(Void) : Void { Combo = createClassObject(ComboBox, "ComboBox", 1, {styleName:this, owner:this}); Combo.addEventListener("chenge", this); Combo.dataProvider = cards2; size(); } // note that setSize is implemented by UIComponent and calls size(), after setting // __width and __height function size(Void) : Void { Combo.setSize(100, layoutHeight); Combo._x = (layoutWidth-100)/2; Combo._y = (layoutHeight-16)/2; } function setValue(str:String, item:Object, sel:Boolean) : Void { Combo._visible = (item!=undefined); Combo.editable=true; Combo.selectedIndex=str; } function getPreferredHeight(Void) : Number { return 16; } function getPreferredWidth(Void) : Number { return 100; } function chenge() { listOwner.editField(getCellIndex().itemIndex, getDataLabel(), Combo.selectedItem); } } 環境としては同じだとおもって聞いていたのですが、 FlexのDataGridのRendererとして使用しているのですが、このソースでできないってことはFlexとFlashで違うということなのでしょうか? |
フラット表示 | 前のトピック | 次のトピック |
投稿するにはまず登録を | |