diff options
author | Joas Schilling <coding@schilljs.com> | 2017-06-20 13:48:51 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2017-06-20 13:48:51 +0200 |
commit | 90fa27694a6f454820487dcb1ca4e4ceec90a9a1 (patch) | |
tree | ec6821e7aff73031293a9ef3f6a56a3baa672630 /apps/files_sharing/lib | |
parent | 8b0546e3f9741980ee2c63b3aca04392408b2e02 (diff) | |
download | nextcloud-server-90fa27694a6f454820487dcb1ca4e4ceec90a9a1.tar.gz nextcloud-server-90fa27694a6f454820487dcb1ca4e4ceec90a9a1.zip |
Use PNG version of the icons for shipped activities
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'apps/files_sharing/lib')
5 files changed, 50 insertions, 10 deletions
diff --git a/apps/files_sharing/lib/Activity/Providers/Downloads.php b/apps/files_sharing/lib/Activity/Providers/Downloads.php index eb14c16266c..1e1688d7b0f 100644 --- a/apps/files_sharing/lib/Activity/Providers/Downloads.php +++ b/apps/files_sharing/lib/Activity/Providers/Downloads.php @@ -51,7 +51,11 @@ class Downloads extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/download.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/download.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/download.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; @@ -76,7 +80,11 @@ class Downloads extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/download.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/download.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/download.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; diff --git a/apps/files_sharing/lib/Activity/Providers/Groups.php b/apps/files_sharing/lib/Activity/Providers/Groups.php index 06ccdaa98b3..683927d5735 100644 --- a/apps/files_sharing/lib/Activity/Providers/Groups.php +++ b/apps/files_sharing/lib/Activity/Providers/Groups.php @@ -51,7 +51,11 @@ class Groups extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; @@ -78,7 +82,11 @@ class Groups extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; diff --git a/apps/files_sharing/lib/Activity/Providers/PublicLinks.php b/apps/files_sharing/lib/Activity/Providers/PublicLinks.php index b22ae0aa9b5..98e4ebda2d8 100644 --- a/apps/files_sharing/lib/Activity/Providers/PublicLinks.php +++ b/apps/files_sharing/lib/Activity/Providers/PublicLinks.php @@ -58,7 +58,11 @@ class PublicLinks extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; @@ -90,7 +94,11 @@ class PublicLinks extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; diff --git a/apps/files_sharing/lib/Activity/Providers/RemoteShares.php b/apps/files_sharing/lib/Activity/Providers/RemoteShares.php index 4e7d8ef3e27..6ac0be76ff4 100644 --- a/apps/files_sharing/lib/Activity/Providers/RemoteShares.php +++ b/apps/files_sharing/lib/Activity/Providers/RemoteShares.php @@ -73,7 +73,11 @@ class RemoteShares extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; @@ -100,7 +104,11 @@ class RemoteShares extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; diff --git a/apps/files_sharing/lib/Activity/Providers/Users.php b/apps/files_sharing/lib/Activity/Providers/Users.php index eaab35bba9d..02f47f3775a 100644 --- a/apps/files_sharing/lib/Activity/Providers/Users.php +++ b/apps/files_sharing/lib/Activity/Providers/Users.php @@ -60,7 +60,11 @@ class Users extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; @@ -92,7 +96,11 @@ class Users extends Base { throw new \InvalidArgumentException(); } - $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + if ($this->activityManager->getRequirePNG()) { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.png'))); + } else { + $event->setIcon($this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/share.svg'))); + } $this->setSubjects($event, $subject, $parsedParameters); return $event; |