summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Extension.pm
diff options
context:
space:
mode:
authorDavid Lawrence <dlawrence@mozilla.com>2011-03-22 23:13:03 +0100
committerDavid Lawrence <dlawrence@mozilla.com>2011-03-22 23:13:03 +0100
commit764a1fa6d114eee04b04ec1419052e3e4caa02d2 (patch)
treeb25aaa41ea74b0d65f987a1d02003249eb7244bd /Bugzilla/Extension.pm
parent17d2732fb8e8988291dde7cb31a8e5ce21206815 (diff)
downloadbugzilla-764a1fa6d114eee04b04ec1419052e3e4caa02d2.tar.gz
bugzilla-764a1fa6d114eee04b04ec1419052e3e4caa02d2.tar.xz
Bug 643904 - Bugzilla::Extension should export a web_dir attribute to get full path to the extension's web directory
r/a=mkanat
Diffstat (limited to 'Bugzilla/Extension.pm')
-rw-r--r--Bugzilla/Extension.pm12
1 files changed, 11 insertions, 1 deletions
diff --git a/Bugzilla/Extension.pm b/Bugzilla/Extension.pm
index 857d0d75b..dbfee0971 100644
--- a/Bugzilla/Extension.pm
+++ b/Bugzilla/Extension.pm
@@ -26,7 +26,7 @@ use Bugzilla::Constants;
use Bugzilla::Error;
use Bugzilla::Install::Util qw(
extension_code_files extension_template_directory
- extension_package_directory);
+ extension_package_directory extension_web_directory);
use File::Basename;
use File::Spec;
@@ -214,6 +214,7 @@ sub lib_dir {
sub template_dir { return extension_template_directory(@_); }
sub package_dir { return extension_package_directory(@_); }
+sub web_dir { return extension_web_directory(@_); }
######################
# Helper Subroutines #
@@ -786,6 +787,15 @@ This defaults to the C<template> subdirectory of the L</package_dir>.
If you want to override this method, and you have a F<Config.pm>, you must
override this method in F<Config.pm>.
+=head3 C<web_dir>
+
+The directory that your package's web related files are in, such as css and javascript.
+
+This defaults to the C<web> subdirectory of the L</package_dir>.
+
+If you want to override this method, and you have a F<Config.pm>, you must
+override this method in F<Config.pm>.
+
=head3 C<lib_dir>
The directory where your extension's libraries are.