チェンジセット 1491

差分発生行の前後
無視リスト:
コミット日時:
2008/10/03 03:21:22 (3 ヶ月前)
コミッタ:
n_mattun
ログメッセージ:

最新版うp。

ファイル:

凡例:

変更無し
追加
削除
更新
コピー
移動
  • mxp/specialbutton/as3/src/buttonBox_Labels.as

    r1474 r1491  
    321321                // private Function 
    322322                // -------------------------------------------------------------------// 
    323                 private function updateLabelPosition(){ 
     323                public function updateLabelPosition(){ 
     324                         
     325                        var txtLabelWidth = txtLabel_mc.label_txt.width+Math.abs(txtLabel_mc.__shadowMargin_x); 
     326                         
    324327                        if(imgLabel_mc.visible && txtLabel_mc.visible){ 
    325328                                switch(__imagePosition){ 
     
    364367                                        break; 
    365368                                        case "上中": 
    366                                                 if(imgLabel_mc.width-txtLabel_mc.width > 0){ 
    367                                                         imgLabel_mc.x = 0; 
    368                                                         imgLabel_mc.y = 0; 
    369                                                         txtLabel_mc.x = Math.ceil((imgLabel_mc.width-txtLabel_mc.width) / 2); 
     369                                                if(imgLabel_mc.width-txtLabelWidth > 0){ 
     370                                                        imgLabel_mc.x = 0; 
     371                                                        imgLabel_mc.y = 0; 
     372                                                        txtLabel_mc.x = Math.ceil((imgLabel_mc.width-txtLabelWidth) / 2); 
    370373                                                        txtLabel_mc.y = imgLabel_mc.height+__labelMargin; 
    371374                                                }else{ 
    372                                                         imgLabel_mc.x = Math.ceil((txtLabel_mc.width-imgLabel_mc.width) / 2); 
     375                                                        imgLabel_mc.x = Math.ceil((txtLabelWidth-imgLabel_mc.width) / 2); 
    373376                                                        imgLabel_mc.y = 0; 
    374377                                                        txtLabel_mc.x = 0; 
     
    377380                                        break; 
    378381                                        case "上右": 
    379                                                 if(imgLabel_mc.width-txtLabel_mc.width > 0){ 
    380                                                         imgLabel_mc.x = 0; 
    381                                                         imgLabel_mc.y = 0; 
    382                                                         txtLabel_mc.x = imgLabel_mc.width-txtLabel_mc.width; 
     382                                                if(imgLabel_mc.width-txtLabelWidth > 0){ 
     383                                                        imgLabel_mc.x = 0; 
     384                                                        imgLabel_mc.y = 0; 
     385                                                        txtLabel_mc.x = imgLabel_mc.width-txtLabelWidth; 
    383386                                                        txtLabel_mc.y = imgLabel_mc.height+__labelMargin; 
    384387                                                }else{ 
    385                                                         imgLabel_mc.x = txtLabel_mc.width-imgLabel_mc.width; 
     388                                                        imgLabel_mc.x = txtLabelWidth-imgLabel_mc.width; 
    386389                                                        imgLabel_mc.y = 0; 
    387390                                                        txtLabel_mc.x = 0; 
     
    391394                                        // -------------------------------------------------------------------// 
    392395                                        case "右上": 
    393                                                 imgLabel_mc.x = txtLabel_mc.width+__labelMargin; 
     396                                                imgLabel_mc.x = txtLabelWidth+__labelMargin; 
    394397                                                imgLabel_mc.y = 0; 
    395398                                                txtLabel_mc.x = 0; 
     
    398401                                        case "右中": 
    399402                                                if(imgLabel_mc.height-txtLabel_mc.height > 0){ 
    400                                                         imgLabel_mc.x = txtLabel_mc.width+__labelMargin; 
     403                                                        imgLabel_mc.x = txtLabelWidth+__labelMargin; 
    401404                                                        imgLabel_mc.y = 0; 
    402405                                                        txtLabel_mc.x = 0; 
    403406                                                        txtLabel_mc.y = Math.ceil((imgLabel_mc.height-txtLabel_mc.height) / 2); 
    404407                                                }else{ 
    405                                                         imgLabel_mc.x = txtLabel_mc.width+__labelMargin; 
     408                                                        imgLabel_mc.x = txtLabelWidth+__labelMargin; 
    406409                                                        imgLabel_mc.y = Math.ceil((txtLabel_mc.height-imgLabel_mc.height) / 2); 
    407410                                                        txtLabel_mc.x = 0; 
     
    411414                                        case "右下": 
    412415                                                if(imgLabel_mc.height-txtLabel_mc.height > 0){ 
    413                                                         imgLabel_mc.x = txtLabel_mc.width+__labelMargin; 
     416                                                        imgLabel_mc.x = txtLabelWidth+__labelMargin; 
    414417                                                        imgLabel_mc.y = 0; 
    415418                                                        txtLabel_mc.x = 0; 
    416419                                                        txtLabel_mc.y = imgLabel_mc.height-txtLabel_mc.height; 
    417420                                                }else{ 
    418                                                         imgLabel_mc.x = txtLabel_mc.width+__labelMargin; 
     421                                                        imgLabel_mc.x = txtLabelWidth+__labelMargin; 
    419422                                                        imgLabel_mc.y = txtLabel_mc.height-imgLabel_mc.height; 
    420423                                                        txtLabel_mc.x = 0; 
     
    430433                                        break; 
    431434                                        case "下中": 
    432                                                 if(imgLabel_mc.width-txtLabel_mc.width > 0){ 
     435                                                if(imgLabel_mc.width-txtLabelWidth > 0){ 
    433436                                                        imgLabel_mc.x = 0; 
    434437                                                        imgLabel_mc.y = txtLabel_mc.height+__labelMargin; 
    435                                                         txtLabel_mc.x = Math.ceil((imgLabel_mc.width-txtLabel_mc.width) / 2); 
    436                                                         txtLabel_mc.y = 0; 
    437                                                 }else{ 
    438                                                         imgLabel_mc.x = Math.ceil((txtLabel_mc.width-imgLabel_mc.width) / 2); 
     438                                                        txtLabel_mc.x = Math.ceil((imgLabel_mc.width-txtLabelWidth) / 2); 
     439                                                        txtLabel_mc.y = 0; 
     440                                                }else{ 
     441                                                        imgLabel_mc.x = Math.ceil((txtLabelWidth-imgLabel_mc.width) / 2); 
    439442                                                        imgLabel_mc.y = txtLabel_mc.height+__labelMargin; 
    440443                                                        txtLabel_mc.x = 0; 
     
    443446                                        break; 
    444447                                        case "下右": 
    445                                                 if(imgLabel_mc.width-txtLabel_mc.width > 0){ 
     448                                                if(imgLabel_mc.width-txtLabelWidth > 0){ 
    446449                                                        imgLabel_mc.x = 0; 
    447450                                                        imgLabel_mc.y = txtLabel_mc.height+__labelMargin; 
    448                                                         txtLabel_mc.x = imgLabel_mc.width-txtLabel_mc.width; 
    449                                                         txtLabel_mc.y = 0; 
    450                                                 }else{ 
    451                                                         imgLabel_mc.x = txtLabel_mc.width-imgLabel_mc.width; 
     451                                                        txtLabel_mc.x = imgLabel_mc.width-txtLabelWidth; 
     452                                                        txtLabel_mc.y = 0; 
     453                                                }else{ 
     454                                                        imgLabel_mc.x = txtLabelWidth-imgLabel_mc.width; 
    452455                                                        imgLabel_mc.y = txtLabel_mc.height+__labelMargin; 
    453456                                                        txtLabel_mc.x = 0; 
  • mxp/specialbutton/as3/src/buttonBox_textLabels.as

    r1474 r1491  
    8383                        __shadowMargin_x = _nums[0]; 
    8484                        __shadowMargin_y = _nums[1]; 
    85                         shadow_txt.x = _nums[0]; 
    86                         shadow_txt.y = _nums[1]; 
     85                         
     86                        if(_nums[0] > 0){ 
     87                                shadow_txt.x = _nums[0]; 
     88                                label_txt.x  = 0; 
     89                        }else{ 
     90                                shadow_txt.x = 0; 
     91                                label_txt.x  = -(_nums[0]); 
     92                        } 
     93                        if(_nums[1] > 0){ 
     94                                shadow_txt.y = _nums[1]; 
     95                                label_txt.y  = 0; 
     96                        }else{ 
     97                                shadow_txt.y = 0; 
     98                                label_txt.y  = -(_nums[1]); 
     99                        } 
    87100                } 
    88101                // -------------------------------------------------------------------// 
     
    155168                        lbl_fmt.size            = __size; 
    156169                        lbl_fmt.color       = __labelColor; 
     170                        label_txt.defaultTextFormat = lbl_fmt; 
    157171                        label_txt.setTextFormat(lbl_fmt); 
    158172                        //label 
     
    177191                        sdw_fmt.size            = __size; 
    178192                        sdw_fmt.color       = __shadowColor; 
     193                        shadow_txt.defaultTextFormat = sdw_fmt; 
    179194                        shadow_txt.setTextFormat(sdw_fmt); 
    180195                        if(__autoSize){ 
     
    196211                        } 
    197212                         
    198                         checkBorderLine(); 
     213                        //checkBorderLine(); 
    199214                } 
    200215                // -------------------------------------------------------------------// 
  • mxp/specialbutton/as3/src/sample.txt

    r1449 r1491  
    1 // 必要なパッケージの読み込み. 
    2 import flash.utils.getDefinitionByName; 
    3 import flash.geom.*; 
    4 import flash.display.MovieClip; 
    5 import flash.display.Shape; 
    6 import flash.display.Loader; 
    7 import flash.events.*; 
    8 import flash.net.URLRequest; 
    9 import flash.text.*; 
    10 import flash.display.GradientType; 
    11 import flash.display.SpreadMethod; 
    12 import flash.text.TextFieldAutoSize; 
     1 
     2■不具合の残りリスト 
     3 Cornerにアルファが通用していない(ジャスト0はなぜか大丈夫) 
     4 Cornerに矛盾が発生するデカい値を入れるとCornerがはみ出して表示される 
     5 
     6 
     7■これから実装するもの 
     8 up/over/dowm/disable時のviewまわり