Skip to content

Commit

Permalink
Formatting.
Browse files Browse the repository at this point in the history
  • Loading branch information
rockon999 committed Mar 31, 2017
1 parent 2e2936f commit b1316c9
Show file tree
Hide file tree
Showing 12 changed files with 0 additions and 52 deletions.
1 change: 0 additions & 1 deletion [email protected]/compatibility.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ const Me = imports.misc.extensionUtils.getCurrentExtension();

const Util = Me.imports.util;


const SHELL_VERSION = Util.get_shell_version();

/* st-border-image in 3.14 uses strings, not Gio.File */
Expand Down
1 change: 0 additions & 1 deletion [email protected]/convenience.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ const Gio = imports.gi.Gio;
const Config = imports.misc.config;
const ExtensionUtils = imports.misc.extensionUtils;


/**
* initTranslations:
* @domain: (optional): the gettext domain to use
Expand Down
5 changes: 0 additions & 5 deletions [email protected]/events.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const Theming = Me.imports.theming;
const Transitions = Me.imports.transitions;
const Util = Me.imports.util;


const USER_THEME_SCHEMA = 'org.gnome.shell.extensions.user-theme';

/**
Expand All @@ -39,7 +38,6 @@ const USER_THEME_SCHEMA = 'org.gnome.shell.extensions.user-theme';
*
*/


/**
* Intialize.
*
Expand Down Expand Up @@ -76,7 +74,6 @@ function init() {

this._windowCreatedSig = display.connect_after('window-created', Lang.bind(this, _windowCreated));


/* Apparently Ubuntu is wierd and does this different than a common Gnome installation. */
// TODO: Look into this.

Expand Down Expand Up @@ -150,7 +147,6 @@ function cleanup() {
this.windows = null;
}


/* Event Handlers */

/**
Expand Down Expand Up @@ -275,7 +271,6 @@ function _windowCreated(display, window) {
}
}


/**
* Handles any window updates. Contains the core logic of this extension.
*
Expand Down
3 changes: 0 additions & 3 deletions [email protected]/extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@ const Theming = Me.imports.theming;
const Transitions = Me.imports.transitions;
const Util = Me.imports.util;




const USER_THEME_SCHEMA = 'org.gnome.shell.extensions.user-theme';

// TODO: Something isn't obeying custom coloring...
Expand Down
1 change: 0 additions & 1 deletion [email protected]/prefs.js/preferences/app_row.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,6 @@ const CustomRow = new Lang.Class({
}
});


const AddAppRow = new Lang.Class({
Name: 'DynamicPanelTransparency_AddAppRow',
Extends: Gtk.ListBoxRow,
Expand Down
1 change: 0 additions & 1 deletion [email protected]/prefs.js/preferences/demo_panel.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ const Me = imports.misc.extensionUtils.getCurrentExtension();

const Compatibility = Me.imports.compatibility;


const SCALE_FACTOR = 255.9999999;

const DemoPanel = new Lang.Class({
Expand Down
26 changes: 0 additions & 26 deletions [email protected]/prefs.js/preferences/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ const _ = Gettext.gettext;
const gs_ = imports.gettext.domain('gnome-shell').gettext;
const gtk30_ = imports.gettext.domain('gtk30').gettext;


const GNOME_BACKGROUND_SCHEMA = 'org.gnome.desktop.background';

/* Settings Keys */
Expand Down Expand Up @@ -139,7 +138,6 @@ function buildPrefsWidget() {
/* Used for special functions occasionally. */
let extra_btn = builder.get_object('extra_btn');


/* Only show the panel & extra button on relevant pages. */
main_notebook.connect('switch-page', Lang.bind(this, function(notebook, page, index) {
if (index === Page.FOREGROUND || index === Page.BACKGROUND) {
Expand Down Expand Up @@ -220,7 +218,6 @@ function buildPrefsWidget() {
panel_demo.set_background_color({ red: 0, green: 0, blue: 0 });
}


let enable_text_color = settings.get_boolean(SETTINGS_ENABLE_TEXT_COLOR);
let enable_maximized_text_color = settings.get_boolean(SETTINGS_ENABLE_MAXIMIZED_TEXT_COLOR);

Expand Down Expand Up @@ -264,7 +261,6 @@ function buildPrefsWidget() {
}));
transition_type_box.set_active_id('' + settings.get_int(SETTINGS_TRANSITION_TYPE) + '');


let force_transition = builder.get_object('force_transition_check');
force_transition.set_active(settings.get_boolean(SETTINGS_FORCE_ANIMATION));

Expand Down Expand Up @@ -351,7 +347,6 @@ function buildPrefsWidget() {
temp_settings.store(SETTINGS_REMOVE_PANEL_STYLING, new GLib.Variant('b', widget.get_active()));
}));


let maximized_text_color_btn = builder.get_object('maximized_text_color_btn');
let maximized_text_color = settings.get_value(SETTINGS_MAXIMIZED_TEXT_COLOR).deep_unpack();

Expand Down Expand Up @@ -394,7 +389,6 @@ function buildPrefsWidget() {
}
}));


let text_color_btn = builder.get_object('text_color_btn');
let text_color = settings.get_value(SETTINGS_TEXT_COLOR).deep_unpack();

Expand All @@ -414,7 +408,6 @@ function buildPrefsWidget() {
panel_demo.set_text_color({ red: rgb[RED], green: rgb[GREEN], blue: rgb[BLUE], alpha: 1.0 });
}));


let text_shadow_switch = builder.get_object('text_shadow_switch');
text_shadow_switch.set_active(settings.get_boolean(SETTINGS_TEXT_SHADOW));

Expand Down Expand Up @@ -619,7 +612,6 @@ function buildPrefsWidget() {
}
}));


let icon_shadow = builder.get_object('icon_shadow_switch');
icon_shadow.set_active(settings.get_boolean(SETTINGS_ICON_SHADOW));

Expand Down Expand Up @@ -793,7 +785,6 @@ function buildPrefsWidget() {
let color = Util.gdk_to_css_color(color_btn.get_rgba());
let alpha = +(color_btn.get_rgba().alpha.toFixed(2));


let rgba = [color.red, color.green, color.blue, alpha];

temp_settings.store(SETTINGS_ICON_SHADOW_COLOR, new GLib.Variant('(iiid)', rgba));
Expand Down Expand Up @@ -827,8 +818,6 @@ function buildPrefsWidget() {
}));
}



/* Setup Background Tab */
{
let background_color_switch = builder.get_object('background_color_switch');
Expand Down Expand Up @@ -905,8 +894,6 @@ function buildPrefsWidget() {
temp_settings.store(SETTINGS_MAXIMIZED_OPACITY, new GLib.Variant('i', widget.adjustment.get_value()));
}));



/* Minimum opacity control */
let minimum_scale = builder.get_object('minimum_scale');
/* Init value. */
Expand All @@ -932,7 +919,6 @@ function buildPrefsWidget() {
temp_settings.store(SETTINGS_UNMAXIMIZED_OPACITY, new GLib.Variant('i', widget.adjustment.get_value()));
}));


/* Convert & scale color. */
let panel_color = settings.get_value(SETTINGS_PANEL_COLOR).deep_unpack();

Expand All @@ -951,7 +937,6 @@ function buildPrefsWidget() {
panel_demo.set_background_color({ red: rgb[RED], green: rgb[GREEN], blue: rgb[BLUE] });
}));


let hide_corners = builder.get_object('hide_corners_check');
hide_corners.set_active(settings.get_boolean(SETTINGS_HIDE_CORNERS));

Expand All @@ -960,8 +945,6 @@ function buildPrefsWidget() {
}));
}



/* Setup App Settings Tab */
{
let app_list = builder.get_object('app_list');
Expand Down Expand Up @@ -1089,7 +1072,6 @@ function buildPrefsWidget() {
let obj = Convenience.getSchemaObj('org.gnome.shell.extensions.dynamic-panel-transparency.appOverrides');
let app_settings = new Gio.Settings({ path: custom_path, settings_schema: obj });


let content_area = dialog.get_content_area();
content_area.add(app_prefs_builder.get_object('main_box'));

Expand Down Expand Up @@ -1321,7 +1303,6 @@ function buildPrefsWidget() {
dialog.add_button(gtk30_("_Cancel"), Gtk.ResponseType.CANCEL);
dialog.add_button(gtk30_("_OK"), Gtk.ResponseType.OK);


let content_area = dialog.get_content_area();
content_area.add(builder.get_object('wm_class_contents'));

Expand Down Expand Up @@ -1359,13 +1340,9 @@ function buildPrefsWidget() {
dialog.destroy();
}
}));

app_list.add(add);


}


/* Util function to find UI elements in a GTK dialog. */
function find(container, names, level = 0) {
let target = null;
Expand All @@ -1381,7 +1358,6 @@ function buildPrefsWidget() {
return target;
}


/* Setup About Tab */
{
/* Find the stack */
Expand All @@ -1392,7 +1368,6 @@ function buildPrefsWidget() {

let stack = find(contents, ['box', 'stack']);


/* Find the license page. */
let license_page = find(stack, ['license_page']);

Expand Down Expand Up @@ -1446,7 +1421,6 @@ function buildPrefsWidget() {
opacity_revealer.set_reveal_child(settings.get_boolean(SETTINGS_ENABLE_OPACITY));
}));


let restart_dialog = builder.get_object('restart_dialog');

/* Setup buttons. */
Expand Down
1 change: 0 additions & 1 deletion [email protected]/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ const Util = Me.imports.util;
const GLib = imports.gi.GLib;
const Gio = imports.gi.Gio;


/* This might impair visibility of the code, but it makes my life a thousand times simpler */
/* settings.js takes a key and watches for it to change in Gio.Settings & creates a getter for it. */
/* Also can parse, handle, etc. a setting. */
Expand Down
2 changes: 0 additions & 2 deletions [email protected]/stylesheet.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
background-color: rgba(0, 0, 0, 0);
}


/* Used to remove odd effects when full transparency is needed. */

.panel-effect-transparency {
Expand All @@ -16,7 +15,6 @@
background-gradient-end: transparent;
}


/* Used to remove backgrounds when full transparency is needed. */

.panel-background-image-transparency {
Expand Down
5 changes: 0 additions & 5 deletions [email protected]/theming.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ const Util = Me.imports.util;
/* Convenience constant for the shell panel. */
const Panel = Main.panel;


/* Constants for theme opacity detection. */
const THEME_OPACITY_THRESHOLD = 150;

Expand All @@ -28,7 +27,6 @@ const ALPHA_THRESHOLD = 24;
/* Scale factor for color conversion. */
const SCALE_FACTOR = 255;


/**
* Intialize.
*
Expand Down Expand Up @@ -112,7 +110,6 @@ function register_text_shadow(text_color, text_position) {
let text_color_css = 'rgba(' + text_color.red + ', ' + text_color.green + ', ' + text_color.blue + ', ' + text_color.alpha.toFixed(2) + ')';
let text_position_css = '' + text_position[0] + 'px ' + text_position[1] + 'px ' + text_position[2] + 'px';


register_style('dpt-panel-text-shadow');

return apply_stylesheet_css('.dpt-panel-text-shadow .panel-button { text-shadow: ' + text_position_css + ' ' + text_color_css + '; }', 'panel-text-shadow');
Expand Down Expand Up @@ -149,7 +146,6 @@ function register_icon_shadow(icon_color, icon_position) {
let icon = apply_stylesheet_css('.dpt-panel-icon-shadow .system-status-icon { icon-shadow: ' + icon_position_css + ' ' + icon_color_css + '; }', 'panel-icon-shadow');
let arrow = apply_stylesheet_css('.dpt-panel-arrow-shadow .popup-menu-arrow { icon-shadow: ' + icon_position_css + ' ' + icon_color_css + '; }', 'panel-arrow-shadow');


register_style('dpt-panel-icon-shadow');
register_style('dpt-panel-arrow-shadow');

Expand Down Expand Up @@ -339,7 +335,6 @@ function set_corner_color(color) {

let opacity = Util.clamp(color.alpha / SCALE_FACTOR, 0, 1);


/* I strongly dislike using a deprecated method (set_style)
* but this is a hold over from the older extension code and
* the only way to keep per-app coloring working with corners. */
Expand Down
3 changes: 0 additions & 3 deletions [email protected]/transitions.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ function update_transition_type() {
this.transition_type = TransitionType.from_index(Settings.get_transition_type());
}


/**
* Get the current status of the panel's transparency.
*
Expand Down Expand Up @@ -319,7 +318,6 @@ function fade_out(params) {

}


/**
* Fades the panel's alpha to 0. Used for opening the overview & displaying the screenShield.
*
Expand Down Expand Up @@ -382,7 +380,6 @@ function blank_fade_out(params) {
}
}


/**
* Updates the alpha value of the corners' coloring. Slightly awkward overlap is unavoidable.
*
Expand Down
3 changes: 0 additions & 3 deletions [email protected]/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
const GLib = imports.gi.GLib;
const Gio = imports.gi.Gio;


/* Global Utility Variables */
const MAXIMIZED_HEIGHT_BUFFER = 1;
const MAXIMIZED_WIDTH_BUFFER = 5;
Expand All @@ -15,7 +14,6 @@ const MINOR_VERSION = parseInt(imports.misc.config.PACKAGE_VERSION.split('.')[1]
/* Permission setting for created files. */
const PERMISSIONS_MODE = parseInt('0744', 8);


/* Utility Variable Access */

/**
Expand Down Expand Up @@ -48,7 +46,6 @@ function get_shell_version() {
return { major: MAJOR_VERSION, minor: MINOR_VERSION };
}


/* Utility Functions */

/**
Expand Down

0 comments on commit b1316c9

Please sign in to comment.