| 160 |
public static const NICO_WARI_HEIGHT:int = 56; |
public static const NICO_WARI_HEIGHT:int = 56; |
| 161 |
public static const NICO_WARI_WIDTH:int = 544; |
public static const NICO_WARI_WIDTH:int = 544; |
| 162 |
|
|
| 163 |
public static const NICO_SWF_HEIGHT:int = 384; |
public static const NICO_SWF_HEIGHT:int = 368; |
| 164 |
public static const NICO_SWF_WIDTH:int = 512; |
public static const NICO_SWF_WIDTH:int = 512; |
| 165 |
|
|
| 166 |
public static const NICO_VIDEO_WINDOW_HEIGHT:int = 384; |
// 640×368 |
| 167 |
|
public static const NICO_VIDEO_WINDOW_HEIGHT:int = 368; |
| 168 |
public static const NICO_VIDEO_WINDOW_WIDTH:int = 512; |
public static const NICO_VIDEO_WINDOW_WIDTH:int = 512; |
| 169 |
public static const NICO_VIDEO_WINDOW_WIDTH_WIDE_MODE:int = 640; |
public static const NICO_VIDEO_WINDOW_WIDTH_WIDE_MODE:int = 640; |
| 170 |
|
|
| 171 |
|
// 864×486 |
| 172 |
|
public static const NICO_VIDEO_NEW_WINDOW_WIDTH_WIDE_MODE:int = 864 |
| 173 |
|
public static const NICO_VIDEO_NEW_WINDOW_WIDTH:int = 654; |
| 174 |
|
public static const NICO_VIDEO_NEW_WINDOW_HEIGHT:int = 486; |
| 175 |
|
|
| 176 |
public static const NICO_VIDEO_PADDING:int = 10; |
public static const NICO_VIDEO_PADDING:int = 10; |
| 177 |
|
|
| 178 |
public static const WIDE_MODE_ASPECT_RATIO:Number = 1.7; |
public static const WIDE_MODE_ASPECT_RATIO:Number = 1.7; |
| 212 |
|
|
| 213 |
private var _isLengthwisePreferred:Boolean = true; |
private var _isLengthwisePreferred:Boolean = true; |
| 214 |
|
|
| 215 |
|
/** 新サイズ 864×486ピクセル 旧サイズ 640×368ピクセル */ |
| 216 |
|
private var _useOldVersionVideoSize:Boolean = false; |
| 217 |
|
|
| 218 |
[Embed(source="/player/NNDDicons_play_20x20.png")] |
[Embed(source="/player/NNDDicons_play_20x20.png")] |
| 219 |
private var icon_Play:Class; |
private var icon_Play:Class; |
| 220 |
|
|
| 1288 |
} |
} |
| 1289 |
|
|
| 1290 |
/** |
/** |
| 1291 |
|
* |
| 1292 |
|
* @param bool |
| 1293 |
|
* |
| 1294 |
|
*/ |
| 1295 |
|
public function isUseOldVersionVideoSize(bool:Boolean):void |
| 1296 |
|
{ |
| 1297 |
|
this._useOldVersionVideoSize = bool; |
| 1298 |
|
} |
| 1299 |
|
|
| 1300 |
|
|
| 1301 |
|
/** |
| 1302 |
* videoDisplayの大きさを動画にあわせ、同時にウィンドウの大きさを変更します。 |
* videoDisplayの大きさを動画にあわせ、同時にウィンドウの大きさを変更します。 |
| 1303 |
* フルスクリーン時に呼ばれても何もしません。 |
* フルスクリーン時に呼ばれても何もしません。 |
| 1304 |
*/ |
*/ |
| 1311 |
} |
} |
| 1312 |
|
|
| 1313 |
//再生窓の既定の大きさ |
//再生窓の既定の大きさ |
| 1314 |
var videoWindowHeight:int = PlayerController.NICO_VIDEO_WINDOW_HEIGHT * ratio; |
var videoWindowHeight:int; |
| 1315 |
var videoWindowWidth:int = PlayerController.NICO_VIDEO_WINDOW_WIDTH * ratio; |
var videoWindowWidth:int; |
| 1316 |
|
|
| 1317 |
|
if (_useOldVersionVideoSize) |
| 1318 |
|
{ |
| 1319 |
|
videoWindowHeight = PlayerController.NICO_VIDEO_WINDOW_HEIGHT * ratio; |
| 1320 |
|
videoWindowWidth = PlayerController.NICO_VIDEO_WINDOW_WIDTH * ratio; |
| 1321 |
|
}else |
| 1322 |
|
{ |
| 1323 |
|
videoWindowHeight = PlayerController.NICO_VIDEO_NEW_WINDOW_HEIGHT * ratio; |
| 1324 |
|
videoWindowWidth = PlayerController.NICO_VIDEO_NEW_WINDOW_WIDTH_WIDE_MODE * ratio; |
| 1325 |
|
} |
| 1326 |
|
|
| 1327 |
//ニコ割窓の既定の大きさ |
//ニコ割窓の既定の大きさ |
| 1328 |
var nicowariWindowHeight:int = PlayerController.NICO_WARI_HEIGHT * ratio; |
var nicowariWindowHeight:int = PlayerController.NICO_WARI_HEIGHT * ratio; |
| 1356 |
trace("enable 16:9 mode"); |
trace("enable 16:9 mode"); |
| 1357 |
} |
} |
| 1358 |
|
|
| 1359 |
videoWindowHeight = PlayerController.NICO_VIDEO_WINDOW_HEIGHT * ratio; |
|
| 1360 |
if(this.videoInfoView.isEnableWideMode && isWideVideo){ |
if (_useOldVersionVideoSize) |
| 1361 |
// logManager.addLog("ワイド(16:9)モード"); |
{ |
| 1362 |
videoWindowWidth = (PlayerController.NICO_VIDEO_WINDOW_WIDTH_WIDE_MODE + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
videoWindowHeight = PlayerController.NICO_VIDEO_WINDOW_HEIGHT * ratio; |
| 1363 |
}else{ |
if(this.videoInfoView.isEnableWideMode && isWideVideo){ |
| 1364 |
// logManager.addLog("ノーマル(4:3)モード"); |
videoWindowWidth = (PlayerController.NICO_VIDEO_WINDOW_WIDTH_WIDE_MODE + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
| 1365 |
videoWindowWidth = (PlayerController.NICO_VIDEO_WINDOW_WIDTH + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
}else{ |
| 1366 |
|
videoWindowWidth = (PlayerController.NICO_VIDEO_WINDOW_WIDTH + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
| 1367 |
|
} |
| 1368 |
|
} |
| 1369 |
|
else |
| 1370 |
|
{ |
| 1371 |
|
videoWindowHeight = PlayerController.NICO_VIDEO_NEW_WINDOW_HEIGHT * ratio; |
| 1372 |
|
if(this.videoInfoView.isEnableWideMode && isWideVideo){ |
| 1373 |
|
videoWindowWidth = (PlayerController.NICO_VIDEO_NEW_WINDOW_WIDTH_WIDE_MODE + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
| 1374 |
|
}else{ |
| 1375 |
|
videoWindowWidth = (PlayerController.NICO_VIDEO_NEW_WINDOW_WIDTH + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
| 1376 |
|
} |
| 1377 |
} |
} |
| 1378 |
|
|
| 1379 |
//動画そのものはセンターに表示 |
//動画そのものはセンターに表示 |
| 1397 |
|
|
| 1398 |
//動画の大きさにウィンドウの大きさを合わせるとき(videoHeightが0の時は動画がまだ読み込まれていないのでスキップ) |
//動画の大きさにウィンドウの大きさを合わせるとき(videoHeightが0の時は動画がまだ読み込まれていないのでスキップ) |
| 1399 |
|
|
| 1400 |
videoWindowHeight = this.videoDisplay.videoObject.videoHeight * ratio; |
videoWindowHeight = (this.videoDisplay.videoObject.videoHeight + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
| 1401 |
videoWindowWidth = this.videoDisplay.videoObject.videoWidth * ratio; |
videoWindowWidth = (this.videoDisplay.videoObject.videoWidth + PlayerController.NICO_VIDEO_PADDING*2) * ratio; |
| 1402 |
|
|
| 1403 |
this.videoDisplay.setConstraintValue("bottom", 0); |
this.videoDisplay.setConstraintValue("bottom", 0); |
| 1404 |
this.videoDisplay.setConstraintValue("left", 0); |
this.videoDisplay.setConstraintValue("left", 0); |
| 1422 |
//SWF再生か? |
//SWF再生か? |
| 1423 |
|
|
| 1424 |
//SWFの場合は一律でサイズを固定 |
//SWFの場合は一律でサイズを固定 |
| 1425 |
videoWindowHeight = PlayerController.NICO_VIDEO_WINDOW_HEIGHT * ratio; |
if (_useOldVersionVideoSize) |
| 1426 |
videoWindowWidth = PlayerController.NICO_VIDEO_WINDOW_WIDTH * ratio; |
{ |
| 1427 |
|
videoWindowHeight = PlayerController.NICO_VIDEO_WINDOW_HEIGHT * ratio; |
| 1428 |
|
videoWindowWidth = PlayerController.NICO_VIDEO_WINDOW_WIDTH * ratio; |
| 1429 |
|
} |
| 1430 |
|
else |
| 1431 |
|
{ |
| 1432 |
|
videoWindowHeight = PlayerController.NICO_VIDEO_NEW_WINDOW_HEIGHT * ratio; |
| 1433 |
|
videoWindowWidth = PlayerController.NICO_VIDEO_NEW_WINDOW_WIDTH * ratio; |
| 1434 |
|
} |
| 1435 |
|
|
| 1436 |
} |
} |
| 1437 |
|
|
| 1441 |
if(videoPlayer.canvas_nicowari.height < 1 ){ |
if(videoPlayer.canvas_nicowari.height < 1 ){ |
| 1442 |
//ニコ割領域が表示されていなければ、その文余分に高さを設定 |
//ニコ割領域が表示されていなければ、その文余分に高さを設定 |
| 1443 |
videoWindowHeight += int(videoWindowWidth / rate); |
videoWindowHeight += int(videoWindowWidth / rate); |
| 1444 |
|
videoWindowHeight += 20; |
| 1445 |
} |
} |
| 1446 |
|
|
| 1447 |
this.videoPlayer.nativeWindow.height += int(videoWindowHeight - this.videoPlayer.canvas_video_back.height); |
this.videoPlayer.nativeWindow.height += int(videoWindowHeight - this.videoPlayer.canvas_video_back.height); |