Skip to content

Commit

Permalink
FELIX-5223 : [IE11][Edge]: Fields in OSGI Configuration Manager are n…
Browse files Browse the repository at this point in the history
…ot editable. Apply patch from Ana Vinatoru

git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1744519 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
cziegeler committed May 19, 2016
1 parent 1ba632e commit 6016205
Show file tree
Hide file tree
Showing 6 changed files with 61 additions and 28 deletions.
2 changes: 1 addition & 1 deletion webconsole/pom.xml
Expand Up @@ -164,7 +164,7 @@
<exclude>src/main/resources/res/lib/jquery-1.8.3.js</exclude>
<exclude>src/main/resources/res/lib/jquery-ui-1.9.2.js</exclude>
<exclude>src/main/resources/res/lib/jquery-ui-i18n-1.7.2.js</exclude>
<exclude>src/main/resources/res/lib/jquery.autosize.min.js</exclude>
<exclude>src/main/resources/res/lib/autosize.min.js</exclude>
<exclude>src/main/resources/res/lib/jquery.cookies-2.2.0.js</exclude>
<exclude>src/main/resources/res/lib/jquery.multifile-1.4.6.js</exclude>
<exclude>src/main/resources/res/lib/jquery.tablesorter-2.0.3.js</exclude>
Expand Down
6 changes: 6 additions & 0 deletions webconsole/src/main/resources/res/lib/autosize.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 0 additions & 7 deletions webconsole/src/main/resources/res/lib/jquery.autosize.min.js

This file was deleted.

32 changes: 31 additions & 1 deletion webconsole/src/main/resources/res/ui/config.css
Expand Up @@ -37,4 +37,34 @@ span.default_value {
float: left; margin-right: .3em;
}
td.col_Exists_body div.ui-icon { margin-left:auto; margin-right: auto }
input.placeholder-active { color: #AAA !important }
input.placeholder-active { color: #AAA !important }

.minHeightTextarea {
min-height: 1.22em;
}

.noPaddingLeft {
padding-left: 0em !important;
}

.configDescription {
padding: 0 0 1em 0 !important;
}

.minWidthCell {
padding-top: 0.5em !important;
min-width: 10em;
}

.paddedCell {
padding-top: 0.5em !important;
padding-bottom: 0.5em !important;
}

.topPaddedText {
padding-top: 0.4em !important;
}

.iconMarginTop {
margin-top: .25em;
}
40 changes: 22 additions & 18 deletions webconsole/src/main/resources/res/ui/config.js
Expand Up @@ -49,7 +49,7 @@ function displayConfigForm(obj) {
var trEl = tr( );
parent.appendChild( trEl );

var tdEl = td( null, { colSpan: "2" } );
var tdEl = td( "noPaddingLeft", { colSpan: "2" } );
trEl.appendChild( tdEl );

var formEl = createElement( "form", null, {
Expand Down Expand Up @@ -114,7 +114,7 @@ function displayConfigForm(obj) {
if (obj.description)
{
trEl = tr( );
tdEl = td( null, { colSpan: "3" } );
tdEl = td( "configDescription", { colSpan: "3" } );
addText( tdEl, obj.description );
trEl.appendChild( tdEl );
bodyEl.appendChild( trEl );
Expand All @@ -140,14 +140,14 @@ function displayConfigForm(obj) {
.dialog('option', 'title', obj.title)
.dialog('open'));

// autosize
$('textarea').trigger('autosize.resize');
// Resize all the textareas based on their content
autosize.update($('textarea'));
}

/* Element */ function addDefaultValue( /* Element */ element ) {
if (element) {
element.appendChild(
createElement('span', 'default_value ui-state-highlight1 ui-icon ui-icon-alert', {
createElement('span', 'default_value ui-state-highlight1 ui-icon ui-icon-alert iconMarginTop', {
title : i18n.dflt_value
})
);
Expand Down Expand Up @@ -179,11 +179,11 @@ function printForm( /* Element */ parent, /* Object */ properties ) {
// create the raw
var trEl = tr( null, null, [
td( null, null, [ optElement ] ),
td( null, null, [ text( attr.name ) ] )
td( "minWidthCell", null, [ text( attr.name ) ] )
]);
parent.appendChild( trEl );

var tdEl = td( null, { style: { width: "99%" } } );
var tdEl = td( "paddedCell", { style: { width: "99%" } } );
trEl.appendChild( tdEl );

if (attr.value != undefined)
Expand Down Expand Up @@ -218,7 +218,9 @@ function printForm( /* Element */ parent, /* Object */ properties ) {

if (attr.description)
{
addText( tdEl, attr.description );
var textWrapper = createElement("div", "topPaddedText");
addText(textWrapper, attr.description );
tdEl.appendChild(textWrapper);
}

if (propList) {
Expand Down Expand Up @@ -249,10 +251,10 @@ function printConfigurationInfo( /* Element */ parent, obj )
);

parent.appendChild( tr( null, null, [
td( null, null, [
td( "paddedCell", null, [
text( i18n.pid )
]),
td( null, null, [
td( "paddedCell", null, [
text( obj.pid )
])
])
Expand All @@ -261,10 +263,10 @@ function printConfigurationInfo( /* Element */ parent, obj )
if (obj.factoryPid)
{
parent.appendChild( tr( null, null, [
td( null, null, [
td( "paddedCell", null, [
text( i18n.fpid )
]),
td( null, null, [
td( "paddedCell", null, [
text( obj.factoryPid )
])
])
Expand All @@ -280,10 +282,10 @@ function printConfigurationInfo( /* Element */ parent, obj )
}

parent.appendChild( tr( null, null, [
td( null, null, [
td( "paddedCell", null, [
text( i18n.binding )
]),
td( null, null, [
td( "paddedCell", null, [
createElement( "input", null, {
type: "text",
name: "$location",
Expand Down Expand Up @@ -316,10 +318,10 @@ function printConfigurationInfo( /* Element */ parent, obj )
});
if ( obj.bundleLocation && obj.bundleLocation != "" ) {
parent.appendChild( tr( null, null, [
td( null, null, [
td( "paddedCell", null, [
text( "" )
]),
td( null, null, [
td( "paddedCell", null, [
text( obj.bundleLocation )
])
])
Expand Down Expand Up @@ -415,10 +417,12 @@ var spanCounter = 0;
} else { // Simple
var textareaEl = createElement( "textarea", null, {
name: prop,
style: { width: width }
style: { width: width },
rows: 1,
class: "minHeightTextarea"
});
addText(textareaEl, value.toString());
$(textareaEl).autosize();
autosize($(textareaEl));
return textareaEl;
}
}
Expand Down
2 changes: 1 addition & 1 deletion webconsole/src/main/resources/templates/main_header.html
Expand Up @@ -23,7 +23,7 @@
<script src="${appRoot}/res/lib/jquery-ui-i18n-1.7.2.js" type="text/javascript"></script>
<script src="${appRoot}/res/lib/jquery.cookies-2.2.0.js" type="text/javascript"></script>
<script src="${appRoot}/res/lib/jquery.tablesorter-2.0.3.js" type="text/javascript"></script>
<script src="${appRoot}/res/lib/jquery.autosize.min.js" type="text/javascript"></script>
<script src="${appRoot}/res/lib/autosize.min.js" type="text/javascript"></script>
<script src="${appRoot}/res/lib/support.js" type="text/javascript"></script>

<script type="text/javascript">
Expand Down

0 comments on commit 6016205

Please sign in to comment.