minor bugfixes

This commit is contained in:
斟酌 鵬兄 2015-09-21 02:04:53 +08:00
parent 88ad9b8a53
commit 54464ce395
5 changed files with 32 additions and 10 deletions

View File

@ -23,6 +23,8 @@
var IDOMObject = __import( "Dandelion.IDOMObject" );
/** @type {Dandelion.IDOMElement} */
var IDOMElement = __import( "Dandelion.IDOMElement" );
/** @type {Astro.Blog.Config} */
var Conf = __import( "Astro.Blog.Config" );
var postData = __import( "System.Net.postData" );
var prettyDate = __import( "Astro.utils.Date.pretty" );
@ -38,6 +40,9 @@
, holdingCtrl = false
, holdingShift = false
/** @type {_AstConf_.SiteFile} */
, config = Conf.get( "SiteFile" )
, contentPanel = Dand.id("asl_viewer")
, canvasView
, contextMenu
@ -301,13 +306,13 @@
)).show();
}
, copyItemLink = function () { return "http://file.astropenguin.net/blog/site-library/" + canvasView.idata.href; }
, copyItemLink = function () { return config.f_host + canvasView.idata.href; }
, copyHash = function () { return canvasView.idata.hash; }
, openAction = function ()
{
if(canvasView.idata.isCollection) openCollection(IDOMElement(canvasView.idata.stage).getDAttribute("id"));
else window.open("http://file.astropenguin.net/blog/site-library/" + canvasView.idata.href);
else window.open( config.f_host + canvasView.idata.href);
}
//// ContextMenu Handlers: Selections

View File

@ -22,7 +22,7 @@
"Plain text" , "plain"
, "AS3" , "as3"
, "bash" , "bash"
, "C#" , "c#"
, "C#" , "csharp"
, "C/C++" , "c"
, "CSS" , "css"
, "php" , "php"
@ -111,8 +111,17 @@
lang = this.lang[this.pSnippeCodeChoice = this.lang.selectedIndex].value;
code = this.code.value;
}
var langName;
for( var i in codeLangs )
{
if( codeLangs[i].keyValue == lang )
{
langName = codeLangs[i].keyName;
break;
}
}
if ( submitted && code )
{
if (!stage)
@ -122,7 +131,7 @@
"v_box"
, [
Dand.wrapne( "pre", code )
, Dand.wrapc( "v_description", "Script language: " + lang )
, Dand.wrapc( "v_description", "Script language: " + langName )
]
, [
new DataKey( "value", code )
@ -146,7 +155,7 @@
temp = stage.lastChild;
temp.removeChild( temp.firstChild );
temp.appendChild( Dand.textNode( "Script language: " + lang ) );
temp.appendChild( Dand.textNode( "Script language: " + langName ) );
temp = stage;

View File

@ -55,7 +55,7 @@ header {
box-shadow: inset 0 0 10px 0 black;
background-image: url(http://file.astropenguin.net/blog/layout-images/home.png);
background-position: 50% 0;
background-position: 50% 90%;
position: absolute;
overflow: hidden;
@ -71,7 +71,7 @@ header {
left: 0;
background-color: rgba( 255, 255, 255, 0.6 );
}
/*
.begin-wrapper:before {
content: "";
position: absolute;
@ -86,7 +86,7 @@ header {
opacity: 0.6;
}
*/
.contact-wrapper {
text-align: center;
position: relative;

View File

@ -25,6 +25,8 @@ a {
text-decoration: none;
}
sup { vertical-align: super; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4, .h1, .h2, .h3, .h4 { font-family: custom-serif; }

View File

@ -7,6 +7,7 @@
background-color: #0C121B;
word-wrap: break-word;
white-space: pre-wrap;
}
@ -27,6 +28,11 @@
padding: 0.2em 0;
}
#commit-message {
padding: 1em;
background-color: #EEE;
}
#commit-sha { color: #666; }
#commit-sha.ok { color: royalblue; }
#commit-sha.failed { color: orangered; }