mirror of
https://github.com/gosticks/PaperWM.git
synced 2026-12-04 04:11:38 +00:00
winprops: support regexps in wm_class
This commit is contained in:
+4
-1
@@ -290,7 +290,10 @@ var winprops = [];
|
||||
function winprop_match_p(meta_window, prop) {
|
||||
let wm_class = meta_window.wm_class || "";
|
||||
let title = meta_window.title;
|
||||
if (prop.wm_class !== wm_class) {
|
||||
if (prop.wm_class.constructor === RegExp) {
|
||||
if (!wm_class.match(prop.wm_class))
|
||||
return false;
|
||||
} else if (prop.wm_class !== wm_class) {
|
||||
return false;
|
||||
}
|
||||
if (prop.title) {
|
||||
|
||||
Reference in New Issue
Block a user