Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
ximper-shell-notification-center
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
ximper-shell-notification-center
Commits
913a5d7f
Commit
913a5d7f
authored
Jul 23, 2022
by
Erik Reider
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed Config and Style not handling custom home-relative paths
parent
71dd3f3f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
functions.vala
src/functions.vala
+10
-2
No files found.
src/functions.vala
View file @
913a5d7f
...
...
@@ -93,10 +93,14 @@ namespace SwayNotificationCenter {
}
}
public
static
string
get_style_path
(
string
?
custom_path
,
public
static
string
get_style_path
(
owned
string
?
custom_path
,
bool
only_system
=
false
)
{
string
[]
paths
=
{};
if
(
custom_path
!=
null
&&
custom_path
.
length
>
0
)
{
// Replaces the home directory relative path with a absolute path
if
(
custom_path
.
get
(
0
)
==
'~'
)
{
custom_path
=
Environment
.
get_home_dir
()
+
custom_path
[
1
:];
}
paths
+=
custom_path
;
}
if
(!
only_system
)
{
...
...
@@ -125,9 +129,13 @@ namespace SwayNotificationCenter {
return
path
;
}
public
static
string
get_config_path
(
string
?
custom_path
)
{
public
static
string
get_config_path
(
owned
string
?
custom_path
)
{
string
[]
paths
=
{};
if
(
custom_path
!=
null
&&
custom_path
.
length
>
0
)
{
// Replaces the home directory relative path with a absolute path
if
(
custom_path
.
get
(
0
)
==
'~'
)
{
custom_path
=
Environment
.
get_home_dir
()
+
custom_path
[
1
:];
}
paths
+=
custom_path
;
}
paths
+=
Path
.
build_path
(
Path
.
DIR_SEPARATOR
.
to_string
(),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment