| Log Message: |
Made changes that locate the Localize handler in $r
the WeBWorK::Request object which is unloaded in nearly every subroutine.
At the moment this seems more appropriate than trying to create a WeBWorK object.
WeBWorK.pm is basically a dispatch routine, which creates a request object and then
initializes it.
The biggest obstacle is handling URLPath. In each case the name of a segment needs a
translation for display purposes. This can't be done statically because, while the paths
are static, the language is not determined until the request comes and might be different
for each course. To handle this we have added an extra parameter (the second one) whenever
a URLPath is created which must be a WeBWorK::Request object. Now the URLPath object knows
the "parent" request that it belongs to and from that can determine language to use for
translation. This involved a lot of routine changes which were done with massive search and
individual replace. There are also checks in the creation routines for URLPath which
insure that the second argument is a WeBWorK::Request object. This reduced errors during the change over.
Going forward the differences are only that one uses $r->maketext() instead of $LH->maketext()
and in the global.conf (overridden by the courses.conf file) there is a new item:
$language = "tr" (or "en" or "fr" );
We need more Translation files in Localize, We need error messages for non-existentant languages.
and eventually we will want easier customization (via Course Configuration or perhaps even individual
preferences)
|