📄 isc_docviewer.js
字号:
/* SmartClient Ajax RIA system Version 6.5/LGPL Development Only (2008-04-30) Copyright 2000-2007 Isomorphic Software, Inc. All rights reserved. "SmartClient" is a trademark of Isomorphic Software, Inc. LICENSE NOTICE INSTALLATION OR USE OF THIS SOFTWARE INDICATES YOUR ACCEPTANCE OF THE SOFTWARE EVALUATION LICENSE AGREEMENT. If you have received this file without an Isomorphic Software license file, please see: http://www.isomorphic.com/licenses/isc_eval_license_050316.html You are not required to accept this agreement, however, nothing else grants you the right to copy or use this software. Unauthorized copying and use of this software is a violation of international copyright law. EVALUATION ONLY This software is provided for limited evaluation purposes only. You must acquire a deployment license from Isomorphic Software in order to use the SmartClient system, or any portion thereof, in any non-evaluation application, including internal or non-commercial applications. PROPRIETARY & PROTECTED MATERIAL This software contains proprietary materials that are protected by contract and intellectual property law. YOU ARE EXPRESSLY PROHIBITED FROM ATTEMPTING TO REVERSE ENGINEER THIS SOFTWARE OR MODIFY THIS SOFTWARE FOR HUMAN READABILITY. CONTACT ISOMORPHIC For more information regarding license rights and restrictions, or to report possible license violations, please contact Isomorphic Software by email (licensing@isomorphic.com) or web (www.isomorphic.com).*/if(window.isc&&window.isc.module_Core&&!window.isc.module_DocViewer){isc.module_DocViewer=1;isc._moduleStart=isc._DocViewer_start=(isc.timestamp?isc.timestamp():new Date().getTime());if(isc._moduleEnd&&(!isc.Log||(isc.Log && isc.Log.logIsDebugEnabled('loadTime')))){isc._pTM={ message:'DocViewer load/parse time: ' + (isc._moduleStart-isc._moduleEnd) + 'ms', category:'loadTime'};if(isc.Log && isc.Log.logDebug)isc.Log.logDebug(isc._pTM.message,'loadTime')else if(isc._preLog)isc._preLog[isc._preLog.length]=isc._pTMelse isc._preLog=[isc._pTM]}isc.defineClass("DocCookieState").addProperties({init:function(){isc.ClassFactory.addGlobalID(this);if(!this.cookieName){this.logError("You must set the 'cookieName' property");return}if(!isc.Page.isLoaded()){isc.Page.setEvent("load",this.getID()+".pageLoaded()")}else{this.load();this.delayCall("processCallback")}},pageLoaded:function(){this.load();this.processCallback()},processCallback:function(){if(this.onload){this.fireCallback(this.onload,["state","data"],[this,this.data])}},load:function(){var _1=isc.Cookie.get(this.cookieName);this.logDebug("loaded: "+_1)if(_1){try{var _2=new Function("return "+_1);this.data=_2()}catch(e){this.logWarn("state cookie corrupt, clearing out and defaulting state.");this.clear()}}if(!this.data)this.data=isc.clone(this.defaultData);return this.data},canUpdate:function(){return isc.Page.isLoaded()},store:function(_1){if(!this.canUpdate())return;if(!_1&&!this.data)return;if(_1)this.data=_1;if(!this.disableCookieStore){var _2=isc.Comm.serialize(this.data);this.logDebug("storing: "+_2+" - length: "+_2.length);isc.Cookie.set(this.cookieName,_2,this.cookiePath,this.cookieDomain,this.cookieExpiration)}},add:function(_1){if(!this.canUpdate())return;if(!this.data)this.data={};isc.addProperties(this.data,_1);this.store()},clear:function(){if(!this.canUpdate())return;this.data=null;isc.Cookie.clear(this.cookieName)},reset:function(){if(!this.canUpdate())return;this.data=isc.clone(this.defaultData);this.store()},getStoredSize:function(_1){if(!_1)_1=this.data;if(!_1)return 0;return isc.Comm.serialize(_1).length}});isc.defineClass("DocFilterField","Canvas");isc.A=isc.DocFilterField.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.height=24;isc.A.overflow="hidden";isc.B.push(isc.A.initWidget=function(){this.Super("initWidget",arguments);var _1=isc.StretchImg.create({autoDraw:false,left:2,top:2,height:20,width:200,src:"[ISO_DOCS_SKIN]/images/DocFilterField/filterfield.png",canHover:true,hoverHeight:1,prompt:"Filter by name (filters as you type)",vertical:false,items:[{width:18,name:"start"},{width:"*",name:"stretch"},{width:7,name:"end"}]});this.form=isc.FormLayout.create({autoDraw:false,left:2,top:3,height:20,width:290,colWidths:[172,"*"],styleName:"filterForm",cellPadding:0,cellSpacing:0,cellBorder:0,fields:[{name:this.fieldName,textBoxStyle:"searchField",height:16,width:"*",showTitle:true,titleOrientation:"right",title:"Filter results"}]},this.formProps);this.addChild(_1);this.addChild(this.form)});isc.B._maxIndex=isc.C+1;isc.defineClass("DocPrefsDialog",isc.Window);isc.A=isc.DocPrefsDialog.getPrototype();isc.A.title="Preferences";isc.A.autoCenter=true;isc.A.showMinimizeButton=false;isc.A.height=140;isc.A.width=500;isc.A.isModal=true;isc.A.bodyDefaults={layoutMargin:0,membersMargin:10};isc.A=isc.DocPrefsDialog.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function(){this.Super("initWidget",arguments);this.addItem(this.$46n());this.addItem(this.$46o())},isc.A.show=function(){var _1=this.docViewer.state;var _2=_1.tab==1?"api":"overview";this.form.setValue("classView",_2);this.Super("show",arguments)},isc.A.$46n=function(){this.form=isc.DynamicForm.create({autoDraw:false,width:300,height:"*",overflow:"visible",numCols:2,colWidths:[120,"*"],fields:[{name:"classView",title:"Default class view",type:"radioGroup",defaultValue:"overview",valueMap:{overview:"Overview Tab",api:"API Tab"},titleHoverHTML:function(){return"When showing a class, should the Overview or API tab be opened by default?"}}]});return this.form},isc.A.$46o=function(){this.buttons=isc.HStack.create({autoDraw:false,membersMargin:5,members:[isc.LayoutSpacer.create(),isc.IButton.create({autoDraw:false,icon:"[ISO_DOCS_SKIN]/images/DocPrefsDialog/ok.png",title:"OK",docPrefs:this,click:"this.docPrefs.okClick()"}),isc.IButton.create({autoDraw:false,icon:"[ISO_DOCS_SKIN]/images/DocPrefsDialog/cancel.png",title:"Cancel",docPrefs:this,click:"this.docPrefs.cancelClick()"}),isc.IButton.create({autoDraw:false,width:150,icon:"[ISO_DOCS_SKIN]/images/DocPrefsDialog/revert.png",title:"Revert To Defaults",docPrefs:this,click:"this.docPrefs.revertClick()"})]});return this.buttons},isc.A.okClick=function(){var _1=this.form.getValues();this.docViewer.state.add({tab:_1.classView=="overview"?0:1});this.hide()},isc.A.cancelClick=function(){this.hide()},isc.A.revertClick=function(){this.$46p=isc.ask("Clear all state and revert to defaults?"+" This will clear saved tree state, size, selection, and other remembered state.",this.getID()+".revertCallback(value)")},isc.A.revertCallback=function(_1){if(_1){this.docViewer.state.reset();this.hide()}});isc.B._maxIndex=isc.C+8;isc.defineClass("DocHelpDialog",isc.Window);isc.A=isc.DocHelpDialog.getPrototype();isc.A.title="Help";isc.A.autoCenter=true;isc.A.autoSize=true;isc.A=isc.DocHelpDialog.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.B.push(isc.A.initWidget=function(){this.Super("initWidget",arguments);this.addItem(this.$46q())},isc.A.$46q=function(){var _1=isc.jsdoc.getDocItem("group:docViewerHelp");return isc.Canvas.create({overflow:"visible",dynamicContents:true,contents:isc.jsdoc.getAttribute(_1,"description")})});isc.B._maxIndex=isc.C+2;isc.defineClass("DocGrid","ListGrid");isc.A=isc.DocGrid.getPrototype();isc.B=isc._allFuncs;isc.C=isc.B._maxIndex;isc.D=isc._funcClasses;isc.D[isc.C]=isc.A.Class;isc.A.alternateRecordStyles=true;isc.A.autoDraw=false;isc.B.push(isc.A.rowOver=function(_1){if(this.updateOnRowOver){if(this.mouseLock)return;this.previewRecord(_1)}},isc.A.rowClick=function(_1,_2,_3){if(this.updateOnRowOver)this.mouseLock=true;if(_1.ref&&this.docViewer&&!this.docViewer.noHistory&&this.docViewer.trackHistory)isc.History.addHistoryEntry(this.docViewer.encodeHistoryID(_1.ref));this.previewRecord();return this.Super("rowClick",arguments)},isc.A.mouseOut=function(){if(this.updateOnRowOver){delete this.mouseLock;var _1=this.getSelectedRecord();if(_1)this.previewRecord()}}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -