X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=0.6.x%2Fjs%2F01_core%2F21_XViewPort.js;fp=0.6.x%2Fjs%2F01_core%2F21_XViewPort.js;h=7c29e7d60ef85b247492820d107c6c795c026d6a;hb=1ed2190f012cf923f7e48d3c0d122aa56c56c5f3;hp=c1a1760a0d38a7ceddca3f356470327bd1cd476e;hpb=a3d03e96ad8c0392ef683eb6c64421e094b96958;p=pettanr%2FclientJs.git
diff --git a/0.6.x/js/01_core/21_XViewPort.js b/0.6.x/js/01_core/21_XViewPort.js
index c1a1760..7c29e7d 100644
--- a/0.6.x/js/01_core/21_XViewPort.js
+++ b/0.6.x/js/01_core/21_XViewPort.js
@@ -75,7 +75,7 @@ X_ViewPort = X_Class_override(
case 'blur' :
case 'focusout' :
- if( X_UA[ 'IE' ] < 9 ){
+ if( 5 < X_UA[ 'IE' ] && X_UA[ 'IE' ] < 9 ){
xnode = X_Node_getXNode( document.activeElement );
if( xnode ){
xnode[ 'listenOnce' ]( [ 'focus', 'blur' ], X_ViewPort_detectFocusForIE );
@@ -107,15 +107,23 @@ X_ViewPort = X_Class_override(
);
function X_ViewPort_detectFocusForIE( e ){
- console.log( 'iefix! ' + e.type + ':' + this.attr( 'tag' ) + ' isActive?:' + ( this[ '_rawObject' ] === document.activeElement ) );
-
+ //console.log( 'iefix! ' + e.type + ':' + this.attr( 'tag' ) + ' isActive?:' + ( this[ '_rawObject' ] === document.activeElement ) );
+ var elmActive = X_Script_try( X_Object_find, [ document, 'activeElement' ] );
X_ViewPort_active = e.type === 'focus';
- if( this[ '_rawObject' ] !== document.activeElement ){
+
+ if( elmActive && this[ '_rawObject' ] !== elmActive ){
this[ 'unlisten' ]( X_ViewPort_active ? 'blur' : 'focus', X_ViewPort_detectFocusForIE );
+ console.log( '>>>>>> activeElement åå¾ ä¸ä¸è´ã' + this._tag );
+ } else
+ if( !elmActive ){
+ console.log( '******** activeElement åå¾ã®ã¨ã©ã¼' );
+ } else if( elmActive ){
+ console.log( '>>>>>> activeElement åå¾' );
};
+
if( X_ViewPort_activeTimerID ){
- X_ViewPort_activeTimerID = X_Timer_remove( X_ViewPort_activeTimerID );
+ X_Timer_remove( X_ViewPort_activeTimerID );
};
X_ViewPort_activeTimerID = X_Timer_once( 16, X_ViewPort_changeFocus );
@@ -251,8 +259,8 @@ X[ 'ViewPort' ] = {
//(((t = document.documentElement) || (t = document.body.parentNode)) && typeof t.ScrollLeft == 'number' ? t : document.body).ScrollLeft;
//(((t = document.documentElement) || (t = document.body.parentNode)) && typeof t.ScrollTop == 'number' ? t : document.body).ScrollTop
- /*
- * TODO X.Doc ã¸
+ // TODO X.Doc ã¸
+ /**
* @alias X.ViewPort.getDocumentSize
*/
'getDocumentSize' : function(){
@@ -595,12 +603,12 @@ if( X_UA_EVENT.W3C ){
} else
if( 6 <= X_UA[ 'IE' ] && X[ 'inHead' ] && !X_UA[ 'ieExeComError' ] ){ // standalone ã®é¤å¤ -> && !X_UA[ 'ieExeComError' ]
// if this script in Head
- document.write( '' );
- X_TEMP._script = document.getElementById( '__ieonload' );
+ //document.write( '' );
+ //X_TEMP._script = document.getElementById( '__ieonload' );
// ä¸ã®ã³ã¼ãã¯ã¹ã¿ã³ãã¢ãã¼ã³çie6ã§ã¨ã©ã¼
- //X_TEMP._script = document.createElement( '' ) ;
- //document.getElementsByTagName( 'head' )[ 0 ].appendChild( X_TEMP._script );
+ X_TEMP._script = document.createElement( '' ) ;
+ document.getElementsByTagName( 'head' )[ 0 ].appendChild( X_TEMP._script );
X_TEMP._script.onreadystatechange = function(){
var s = X_TEMP._script;