Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Browser window title and flavicon on RWT level
Browser window title and flavicon on RWT level [message #129150] Tue, 21 April 2009 11:54 Go to next message
Eclipse UserFriend
Originally posted by: peterka.jiri.gmail.com

Hi all,

is there a way howto set Browser window title and flavicon from RWT
application?

Best regards

Jiri
Re: Browser window title and flavicon on RWT level [message #129182 is a reply to message #129150] Tue, 21 April 2009 12:55 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: markus.wolf.nmmn.com

Hi Jiri

> is there a way howto set Browser window title and flavicon from RWT
> application?
>
in the FAQ is explained on how to create an RWT application:
http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat

With the branding you can define your requested aspects.

Regards
Markus Wolf
--
NMMN - New Media Markets & Networks GmbH
Geschäftsführung: Kfm. Michael Schütt
Finanzamt HH-Altona UStID DE 812 699 852 HRB 71102 Hamburg
HypoVereinsbank - BLZ 200 300 00 - Konto-Nr. 156 29 82

http://www.nmmn.com Tel.: +49 40 284 118 -0
Langbehnstrasse 6 Entwicklung: -720
22761 Hamburg Fax: -999
Re: Browser window title and flavicon on RWT level [message #129209 is a reply to message #129182] Tue, 21 April 2009 13:31 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: peterka.jiri.gmail.com

Hi Markus,

I've overlooked that. Thanks

Jiri

Markus Wolf wrote:
> Hi Jiri
>
>> is there a way howto set Browser window title and flavicon from RWT
>> application?
>>
> in the FAQ is explained on how to create an RWT application:
> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>
> With the branding you can define your requested aspects.
>
> Regards
> Markus Wolf
Re: Browser window title and favicon on RWT level [message #129262 is a reply to message #129182] Tue, 21 April 2009 14:54 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: peterka.jiri.gmail.com

Markus,

I followed this steps, wrote own implementation of AbstractBranding and
this class is instantiated when app is executed. But getTitle() and
other methods are never called.

Don't you know what's wrong? (URL, some other details, etc.)?

Jiri

Markus Wolf wrote:
> Hi Jiri
>
>> is there a way howto set Browser window title and flavicon from RWT
>> application?
>>
> in the FAQ is explained on how to create an RWT application:
> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>
> With the branding you can define your requested aspects.
>
> Regards
> Markus Wolf
Re: Browser window title and favicon on RWT level [message #129336 is a reply to message #129262] Wed, 22 April 2009 07:12 Go to previous messageGo to next message
Stefan   is currently offline Stefan Friend
Messages: 316
Registered: July 2009
Senior Member
Hi,

maybe the URL you're using is wrong? If you specifify "teaParty" as
Servlet-Name in your branding extension your URL should be sth like
"localhost:9090/teaParty" ...

Regards,
Stefan.

Jiri Peterka schrieb:
> Markus,
>
> I followed this steps, wrote own implementation of AbstractBranding and
> this class is instantiated when app is executed. But getTitle() and
> other methods are never called.
>
> Don't you know what's wrong? (URL, some other details, etc.)?
>
> Jiri
>
> Markus Wolf wrote:
>> Hi Jiri
>>
>>> is there a way howto set Browser window title and flavicon from RWT
>>> application?
>>>
>> in the FAQ is explained on how to create an RWT application:
>> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>>
>>
>> With the branding you can define your requested aspects.
>>
>> Regards
>> Markus Wolf
Re: Browser window title and favicon on RWT level [message #129349 is a reply to message #129262] Wed, 22 April 2009 08:15 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: markus.wolf.nmmn.com

Hi Jiri,

> I followed this steps, wrote own implementation of AbstractBranding and
> this class is instantiated when app is executed. But getTitle() and
> other methods are never called.
>
> Don't you know what's wrong? (URL, some other details, etc.)?
>
You should define the following to get this working:

<context-param>
<param-name>org.eclipse.rwt.themes</param-name>
<param-value>my-theme#my-theme.css</param-value>
</context-param>
<context-param>
<param-name>org.eclipse.rwt.brandings</param-name>
<param-value>example.Branding</param-value>
</context-param>

Then you need a file my-theme.css in your root classpath and the class
'example.Branding'. This class must extend the AbstractBranding class of
RWT and override the following methods:
* getServletName() - this must return the servlet mapping url but
without leading slash
* getFavIcon() - this should return the path to the favicon you want to use
* getTitle() - this should return the page title you want to display
* getThemeId() - this should return 'my-theme' as specified in the
web.xml before the dash

Hope that helps :)

Regards
Markus


> Jiri
>
> Markus Wolf wrote:
>> Hi Jiri
>>
>>> is there a way howto set Browser window title and flavicon from RWT
>>> application?
>>>
>> in the FAQ is explained on how to create an RWT application:
>> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>>
>>
>> With the branding you can define your requested aspects.
>>
>> Regards
>> Markus Wolf


--
NMMN - New Media Markets & Networks GmbH
Geschäftsführung: Kfm. Michael Schütt
Finanzamt HH-Altona UStID DE 812 699 852 HRB 71102 Hamburg
HypoVereinsbank - BLZ 200 300 00 - Konto-Nr. 156 29 82

http://www.nmmn.com Tel.: +49 40 284 118 -0
Langbehnstrasse 6 Entwicklung: -720
22761 Hamburg Fax: -999
Re: Browser window title and favicon on RWT level [message #129478 is a reply to message #129349] Wed, 22 April 2009 17:05 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: peterka.jiri.gmail.com

Hi Markus,

thanks for detailed instructions. Nevertheless I've got still the same
problem. getServletName() is called twice and nothing more.

I've tried servlet name in getServletName() as
localhost:8180/rapServlet" or "localhost:8180/ServletTest/rapServlet",...

Web.xml servlet is defined like this:
<servlet>
<servlet-name>rapServlet</servlet-name>
<servlet-class>org.eclipse.rwt.internal.engine.RWTDelegate</servlet-class >
</servlet>

<servlet-mapping>
<servlet-name>rapServlet</servlet-name>
<url-pattern>/index.html</url-pattern>
</servlet-mapping>

Finally URL is http://localhost:8180/ServletTest where "ServletTest" is
Project name in Eclipse. I'm little bit confused with this mapping.
Any idea is welcome. (RAP 1.2 M6)

Best regards

Jiri

Markus Wolf wrote:
> Hi Jiri,
>
>> I followed this steps, wrote own implementation of AbstractBranding and
>> this class is instantiated when app is executed. But getTitle() and
>> other methods are never called.
>>
>> Don't you know what's wrong? (URL, some other details, etc.)?
>>
> You should define the following to get this working:
>
> <context-param>
> <param-name>org.eclipse.rwt.themes</param-name>
> <param-value>my-theme#my-theme.css</param-value>
> </context-param>
> <context-param>
> <param-name>org.eclipse.rwt.brandings</param-name>
> <param-value>example.Branding</param-value>
> </context-param>
>
> Then you need a file my-theme.css in your root classpath and the class
> 'example.Branding'. This class must extend the AbstractBranding class of
> RWT and override the following methods:
> * getServletName() - this must return the servlet mapping url but
> without leading slash
> * getFavIcon() - this should return the path to the favicon you want to use
> * getTitle() - this should return the page title you want to display
> * getThemeId() - this should return 'my-theme' as specified in the
> web.xml before the dash
>
> Hope that helps :)
>
> Regards
> Markus
>
>
>> Jiri
>>
>> Markus Wolf wrote:
>>> Hi Jiri
>>>
>>>> is there a way howto set Browser window title and flavicon from RWT
>>>> application?
>>>>
>>> in the FAQ is explained on how to create an RWT application:
>>> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>>>
>>>
>>> With the branding you can define your requested aspects.
>>>
>>> Regards
>>> Markus Wolf
>
>
Re: Browser window title and favicon on RWT level [message #129491 is a reply to message #129478] Wed, 22 April 2009 17:18 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: markus.wolf.nmmn.com

Hi Jiri,

> thanks for detailed instructions. Nevertheless I've got still the same
> problem. getServletName() is called twice and nothing more.
>
> I've tried servlet name in getServletName() as
> localhost:8180/rapServlet" or "localhost:8180/ServletTest/rapServlet",...
>
> Web.xml servlet is defined like this:
> <servlet>
> <servlet-name>rapServlet</servlet-name>
> <servlet-class>org.eclipse.rwt.internal.engine.RWTDelegate</servlet-class >
> </servlet>
>
> <servlet-mapping>
> <servlet-name>rapServlet</servlet-name>
> <url-pattern>/index.html</url-pattern>
> </servlet-mapping>
>
> Finally URL is http://localhost:8180/ServletTest where "ServletTest" is
> Project name in Eclipse. I'm little bit confused with this mapping.
> Any idea is welcome. (RAP 1.2 M6)
>
You specified '/index.html' as mapped servlet. Therefore using
'index.html' in your Binding as getServletName() should work.

Regards
Markus

> Best regards
>
> Jiri
>
> Markus Wolf wrote:
>> Hi Jiri,
>>
>>> I followed this steps, wrote own implementation of AbstractBranding and
>>> this class is instantiated when app is executed. But getTitle() and
>>> other methods are never called.
>>>
>>> Don't you know what's wrong? (URL, some other details, etc.)?
>>>
>> You should define the following to get this working:
>>
>> <context-param>
>> <param-name>org.eclipse.rwt.themes</param-name>
>> <param-value>my-theme#my-theme.css</param-value>
>> </context-param>
>> <context-param>
>> <param-name>org.eclipse.rwt.brandings</param-name>
>> <param-value>example.Branding</param-value>
>> </context-param>
>>
>> Then you need a file my-theme.css in your root classpath and the class
>> 'example.Branding'. This class must extend the AbstractBranding class of
>> RWT and override the following methods:
>> * getServletName() - this must return the servlet mapping url but
>> without leading slash
>> * getFavIcon() - this should return the path to the favicon you want
>> to use
>> * getTitle() - this should return the page title you want to display
>> * getThemeId() - this should return 'my-theme' as specified in the
>> web.xml before the dash
>>
>> Hope that helps :)
>>
>> Regards
>> Markus
>>
>>
>>> Jiri
>>>
>>> Markus Wolf wrote:
>>>> Hi Jiri
>>>>
>>>>> is there a way howto set Browser window title and flavicon from RWT
>>>>> application?
>>>>>
>>>> in the FAQ is explained on how to create an RWT application:
>>>> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>>>>
>>>>
>>>>
>>>> With the branding you can define your requested aspects.
>>>>
>>>> Regards
>>>> Markus Wolf
>>
>>


--
NMMN - New Media Markets & Networks GmbH
Geschäftsführung: Kfm. Michael Schütt
Finanzamt HH-Altona UStID DE 812 699 852 HRB 71102 Hamburg
HypoVereinsbank - BLZ 200 300 00 - Konto-Nr. 156 29 82

http://www.nmmn.com Tel.: +49 40 284 118 -0
Langbehnstrasse 6 Entwicklung: -720
22761 Hamburg Fax: -999
Re: Browser window title and favicon on RWT level [message #129504 is a reply to message #129491] Wed, 22 April 2009 17:33 Go to previous message
Eclipse UserFriend
Originally posted by: peterka.jiri.gmail.com

Markus, thanks, you're the man! Now it works great :).

Jiri

Markus Wolf wrote:
> Hi Jiri,
>
>> thanks for detailed instructions. Nevertheless I've got still the same
>> problem. getServletName() is called twice and nothing more.
>>
>> I've tried servlet name in getServletName() as
>> localhost:8180/rapServlet" or "localhost:8180/ServletTest/rapServlet",...
>>
>> Web.xml servlet is defined like this:
>> <servlet>
>> <servlet-name>rapServlet</servlet-name>
>> <servlet-class>org.eclipse.rwt.internal.engine.RWTDelegate</servlet-class >
>> </servlet>
>>
>> <servlet-mapping>
>> <servlet-name>rapServlet</servlet-name>
>> <url-pattern>/index.html</url-pattern>
>> </servlet-mapping>
>>
>> Finally URL is http://localhost:8180/ServletTest where "ServletTest" is
>> Project name in Eclipse. I'm little bit confused with this mapping.
>> Any idea is welcome. (RAP 1.2 M6)
>>
> You specified '/index.html' as mapped servlet. Therefore using
> 'index.html' in your Binding as getServletName() should work.
>
> Regards
> Markus
>
>> Best regards
>>
>> Jiri
>>
>> Markus Wolf wrote:
>>> Hi Jiri,
>>>
>>>> I followed this steps, wrote own implementation of AbstractBranding and
>>>> this class is instantiated when app is executed. But getTitle() and
>>>> other methods are never called.
>>>>
>>>> Don't you know what's wrong? (URL, some other details, etc.)?
>>>>
>>> You should define the following to get this working:
>>>
>>> <context-param>
>>> <param-name>org.eclipse.rwt.themes</param-name>
>>> <param-value>my-theme#my-theme.css</param-value>
>>> </context-param>
>>> <context-param>
>>> <param-name>org.eclipse.rwt.brandings</param-name>
>>> <param-value>example.Branding</param-value>
>>> </context-param>
>>>
>>> Then you need a file my-theme.css in your root classpath and the class
>>> 'example.Branding'. This class must extend the AbstractBranding class of
>>> RWT and override the following methods:
>>> * getServletName() - this must return the servlet mapping url but
>>> without leading slash
>>> * getFavIcon() - this should return the path to the favicon you want
>>> to use
>>> * getTitle() - this should return the page title you want to display
>>> * getThemeId() - this should return 'my-theme' as specified in the
>>> web.xml before the dash
>>>
>>> Hope that helps :)
>>>
>>> Regards
>>> Markus
>>>
>>>
>>>> Jiri
>>>>
>>>> Markus Wolf wrote:
>>>>> Hi Jiri
>>>>>
>>>>>> is there a way howto set Browser window title and flavicon from RWT
>>>>>> application?
>>>>>>
>>>>> in the FAQ is explained on how to create an RWT application:
>>>>> http://wiki.eclipse.org/RAP/FAQ#How_do_I_use_a_RWT_standalon e_application_in_Tomcat
>>>>>
>>>>>
>>>>>
>>>>> With the branding you can define your requested aspects.
>>>>>
>>>>> Regards
>>>>> Markus Wolf
>>>
>
>
Previous Topic:Suuport for tabbed properties view?
Next Topic:Problem with RWTLifeCycle / disposed context and Jaas Example implemetation
Goto Forum:
  


Current Time: Tue Apr 23 12:16:16 GMT 2024

Powered by FUDForum. Page generated in 0.04265 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top