[gnome-shell/wip/input-sources: 4/6] candidatePanel: Remove hardcoded styling
- From: Rui Matos <rtcm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/input-sources: 4/6] candidatePanel: Remove hardcoded styling
- Date: Thu, 3 May 2012 11:31:31 +0000 (UTC)
commit de8106967d099d7fba0f826ffb406c2ad4658f5d
Author: Rui Matos <tiagomatos gmail com>
Date: Thu May 3 11:34:30 2012 +0200
candidatePanel: Remove hardcoded styling
The styling should be done in the CSS file.
js/ui/status/candidatePanel.js | 12 +-----------
1 files changed, 1 insertions(+), 11 deletions(-)
---
diff --git a/js/ui/status/candidatePanel.js b/js/ui/status/candidatePanel.js
index 432f89a..8b12144 100644
--- a/js/ui/status/candidatePanel.js
+++ b/js/ui/status/candidatePanel.js
@@ -33,11 +33,6 @@ const ORIENTATION_HORIZONTAL = 0;
const ORIENTATION_VERTICAL = 1;
const ORIENTATION_SYSTEM = 2;
-const topLabelStyle = 'padding: .1em 0em';
-const candidateLabelStyle = 'padding: .1em 0em .1em 0em';
-const candidateTextStyle = 'padding: .1em 0em .1em 0em';
-const separatorStyle = 'height: 2px; padding: 0em';
-
function StCandidateArea(orientation) {
this._init(orientation);
}
@@ -80,12 +75,10 @@ StCandidateArea.prototype = {
for (let i = 0; i < 16; i++) {
let label1 = new St.Label({ text: '1234567890abcdef'.charAt(i) + '.',
style_class: 'popup-menu-item',
- style: candidateLabelStyle,
reactive: true });
let label2 = new St.Label({ text: '' ,
style_class: 'popup-menu-item',
- style: candidateTextStyle,
reactive: true });
if (this._orientation == ORIENTATION_VERTICAL) {
@@ -261,13 +254,11 @@ CandidatePanel.prototype = {
this._boxPointer.bin.set_child(this._stCandidatePanel);
this._stPreeditLabel = new St.Label({ style_class: 'popup-menu-item',
- style: topLabelStyle,
text: '' });
if (!this._preeditVisible) {
this._stPreeditLabel.hide();
}
this._stAuxLabel = new St.Label({ style_class: 'popup-menu-item',
- style: topLabelStyle,
text: '' });
if (!this._auxVisible) {
this._stAuxLabel.hide();
@@ -603,8 +594,7 @@ function Separator() {
Separator.prototype = {
_init: function() {
- this.actor = new St.DrawingArea({ style_class: 'popup-separator-menu-item',
- style: separatorStyle });
+ this.actor = new St.DrawingArea({ style_class: 'popup-separator-menu-item' });
this.actor.connect('repaint', Lang.bind(this, this._onRepaint));
},
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]