forked from Shinonome/dots-hyprland
Merge branch 'end-4:main' into kb_layout_multi_monitor
This commit is contained in:
@@ -250,8 +250,12 @@ export default ({
|
|||||||
className: 'txt-smaller txt-semibold',
|
className: 'txt-smaller txt-semibold',
|
||||||
label: initTimeString,
|
label: initTimeString,
|
||||||
setup: initTimeString == 'Now' ? (self) => {
|
setup: initTimeString == 'Now' ? (self) => {
|
||||||
Utils.timeout(60000, () => self.label = getFriendlyNotifTimeString(notifObject.time))
|
let id = Utils.timeout(60000, () => {
|
||||||
} : () => {},
|
self.label = getFriendlyNotifTimeString(notifObject.time);
|
||||||
|
id = null;
|
||||||
|
});
|
||||||
|
self.connect('destroy', () => { if (id) GLib.source_remove(id) });
|
||||||
|
} : () => { },
|
||||||
});
|
});
|
||||||
const notifText = Box({
|
const notifText = Box({
|
||||||
valign: Gtk.Align.CENTER,
|
valign: Gtk.Align.CENTER,
|
||||||
|
|||||||
@@ -28,16 +28,27 @@ const BarBatteryProgress = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const time = Variable('', {
|
||||||
|
poll: [
|
||||||
|
userOptions.time.interval,
|
||||||
|
() => GLib.DateTime.new_now_local().format(userOptions.time.format),
|
||||||
|
],
|
||||||
|
})
|
||||||
|
|
||||||
|
const date = Variable('', {
|
||||||
|
poll: [
|
||||||
|
userOptions.time.dateInterval,
|
||||||
|
() => GLib.DateTime.new_now_local().format(userOptions.time.dateFormatLong),
|
||||||
|
],
|
||||||
|
})
|
||||||
|
|
||||||
const BarClock = () => Widget.Box({
|
const BarClock = () => Widget.Box({
|
||||||
vpack: 'center',
|
vpack: 'center',
|
||||||
className: 'spacing-h-4 bar-clock-box',
|
className: 'spacing-h-4 bar-clock-box',
|
||||||
children: [
|
children: [
|
||||||
Widget.Label({
|
Widget.Label({
|
||||||
className: 'bar-time',
|
className: 'bar-time',
|
||||||
label: GLib.DateTime.new_now_local().format(userOptions.time.format),
|
label: time.bind(),
|
||||||
setup: (self) => self.poll(userOptions.time.interval, label => {
|
|
||||||
label.label = GLib.DateTime.new_now_local().format(userOptions.time.format);
|
|
||||||
}),
|
|
||||||
}),
|
}),
|
||||||
Widget.Label({
|
Widget.Label({
|
||||||
className: 'txt-norm txt-onLayer1',
|
className: 'txt-norm txt-onLayer1',
|
||||||
@@ -45,10 +56,7 @@ const BarClock = () => Widget.Box({
|
|||||||
}),
|
}),
|
||||||
Widget.Label({
|
Widget.Label({
|
||||||
className: 'txt-smallie bar-date',
|
className: 'txt-smallie bar-date',
|
||||||
label: GLib.DateTime.new_now_local().format(userOptions.time.dateFormatLong),
|
label: date.bind(),
|
||||||
setup: (self) => self.poll(userOptions.time.dateInterval, (label) => {
|
|
||||||
label.label = GLib.DateTime.new_now_local().format(userOptions.time.dateFormatLong);
|
|
||||||
}),
|
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -3,15 +3,15 @@ import SystemTray from 'resource:///com/github/Aylur/ags/service/systemtray.js';
|
|||||||
const { Box, Icon, Button, Revealer } = Widget;
|
const { Box, Icon, Button, Revealer } = Widget;
|
||||||
const { Gravity } = imports.gi.Gdk;
|
const { Gravity } = imports.gi.Gdk;
|
||||||
|
|
||||||
const SysTrayItem = (item) => Button({
|
const SysTrayItem = (item) => item.id !== null ? Button({
|
||||||
className: 'bar-systray-item',
|
className: 'bar-systray-item',
|
||||||
child: Icon({hpack: 'center'}).bind('icon', item, 'icon'),
|
child: Icon({ hpack: 'center' }).bind('icon', item, 'icon'),
|
||||||
setup: (self) => self
|
setup: (self) => self
|
||||||
.hook(item, (self) => self.tooltipMarkup = item['tooltip-markup'])
|
.hook(item, (self) => self.tooltipMarkup = item['tooltip-markup'])
|
||||||
,
|
,
|
||||||
onPrimaryClick: (_, event) => item.activate(event),
|
onPrimaryClick: (_, event) => item.activate(event),
|
||||||
onSecondaryClick: (btn, event) => item.menu.popup_at_widget(btn, Gravity.SOUTH, Gravity.NORTH, null),
|
onSecondaryClick: (btn, event) => item.menu.popup_at_widget(btn, Gravity.SOUTH, Gravity.NORTH, null),
|
||||||
});
|
}) : null;
|
||||||
|
|
||||||
export const Tray = (props = {}) => {
|
export const Tray = (props = {}) => {
|
||||||
const trayContent = Box({
|
const trayContent = Box({
|
||||||
|
|||||||
@@ -14,6 +14,9 @@ exec-once = dbus-update-activation-environment --all
|
|||||||
exec-once = sleep 1 && dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # Some fix idk
|
exec-once = sleep 1 && dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # Some fix idk
|
||||||
exec-once = hyprpm reload
|
exec-once = hyprpm reload
|
||||||
|
|
||||||
|
# Audio
|
||||||
|
exec-once = easyeffects --gapplication-service
|
||||||
|
|
||||||
# Clipboard: history
|
# Clipboard: history
|
||||||
# exec-once = wl-paste --watch cliphist store &
|
# exec-once = wl-paste --watch cliphist store &
|
||||||
exec-once = wl-paste --type text --watch cliphist store
|
exec-once = wl-paste --type text --watch cliphist store
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ binde = Super, Semicolon, splitratio, -0.1 # [hidden]
|
|||||||
binde = Super, Apostrophe, splitratio, +0.1 # [hidden]
|
binde = Super, Apostrophe, splitratio, +0.1 # [hidden]
|
||||||
# Positioning mode
|
# Positioning mode
|
||||||
bind = Super+Alt, Space, togglefloating,
|
bind = Super+Alt, Space, togglefloating,
|
||||||
bind = Super+Alt, F, fakefullscreen,
|
bind = Super+Alt, F, fullscreenstate, 0 3 # Toggle fake fullscreen
|
||||||
bind = Super, F, fullscreen, 0
|
bind = Super, F, fullscreen, 0
|
||||||
bind = Super, D, fullscreen, 1
|
bind = Super, D, fullscreen, 1
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user