Skip to content

Commit

Permalink
1. 在编辑器非全屏状态下,禁用tab插入空格,以便使用tab跳转输入聚焦
Browse files Browse the repository at this point in the history
2. 修正一个路由错误
  • Loading branch information
joyqi committed Oct 19, 2014
1 parent 72eedcd commit 49cae68
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
5 changes: 4 additions & 1 deletion admin/js/pagedown.js
Original file line number Diff line number Diff line change
Expand Up @@ -1571,7 +1571,7 @@ else
if (window.event) {
window.event.returnValue = false;
}
}else if(key.keyCode==9){
}else if(key.keyCode==9 && window.fullScreenEntered){
var tab = {};
tab.textOp = bindCommand("doTab");
doClick(tab);
Expand Down Expand Up @@ -2630,6 +2630,8 @@ else
self.hooks.enterFakeFullScreen();
self.isFakeFullScreen = true;
}

window.fullScreenEntered = true;
} else {
if (self.isFakeFullScreen) {
buttons.exitFullscreen.style.display = 'none';
Expand All @@ -2639,6 +2641,7 @@ else
}

self.isFakeFullScreen = false;
window.fullScreenEntered = false;
}
};
})();
18 changes: 16 additions & 2 deletions var/Widget/Archive.php
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,20 @@ private function indexHandle(Typecho_Db_Query $select, &$hasPushed)
$this->pluginHandle()->indexHandle($this, $select);
}

/**
* 默认的非首页归档处理
*
* @access private
* @param Typecho_Db_Query $select 查询对象
* @param boolean $hasPushed 是否已经压入队列
* @return void
* @throws Typecho_Widget_Exception
*/
private function archiveEmptyHandle(Typecho_Db_Query $select, &$hasPushed)
{
throw new Typecho_Widget_Exception(_t('请求的地址不存在'), 404);
}

/**
* 404页面处理
*
Expand Down Expand Up @@ -1250,8 +1264,8 @@ public function execute()
$handles = array(
'index' => 'indexHandle',
'index_page' => 'indexHandle',
'archive' => 'error404Handle',
'archive_page' => 'error404Handle',
'archive' => 'archiveEmptyHandle',
'archive_page' => 'archiveEmptyHandle',
404 => 'error404Handle',
'single' => 'singleHandle',
'page' => 'singleHandle',
Expand Down

0 comments on commit 49cae68

Please sign in to comment.