зеркало из https://github.com/mozilla/pjs.git
Fix linux installer to be able to use png images instead of XPM. Add new firefox and thunderbird artwork in png forward and remove generic xpms. Bug 265826, r=vlad.
This commit is contained in:
Родитель
ab1ad1555f
Коммит
bc2025a5f4
|
@ -49,6 +49,11 @@ ABS_depth = $(shell cd $(DEPTH) && pwd)
|
|||
installer: installer.cfg firefox.manifest
|
||||
ifneq ($(ABS_topsrcdir),$(ABS_depth))
|
||||
ln -sf $(srcdir)/*.jst $(srcdir)/*.it $(srcdir)/packages* .
|
||||
endif
|
||||
ifndef MOZ_USE_OFFICIAL_BRANDING
|
||||
$(NSINSTALL) -D $(DIST)/install
|
||||
cp $(srcdir)/header.png $(DIST)/install/header.png
|
||||
cp $(srcdir)/watermark.png $(DIST)/install/watermark.png
|
||||
endif
|
||||
$(PERL) $(topsrcdir)/toolkit/mozapps/installer/build_static.pl -config $(CONFIG_DIR) -objdir $(ABS_depth) -srcdir $(ABS_topsrcdir)
|
||||
|
||||
|
|
|
@ -120,7 +120,7 @@ GRE Private Key=Software\mozilla.org\GRE_$GreUniqueID$_PRIVATE_$ProductNameInter
|
|||
; Controls the display of the banner image in the download and install progress dialogs.
|
||||
; Default value is TRUE.
|
||||
Show Banner Image=TRUE
|
||||
Header Image=header.xpm
|
||||
Header Image=header.png
|
||||
|
||||
; Controls the check to see if user is installing on top of a previous
|
||||
; installation of the product. If so, then prompt the user that cleanup
|
||||
|
@ -195,7 +195,7 @@ Message1=It is strongly recommended that you exit all instances of %s before run
|
|||
Message2=Click Cancel to quit Setup and then close any programs you have running. Click Next to continue the Setup program.
|
||||
;*** LOCALIZE ME BABY ***
|
||||
Message3=Click Next to continue installing %s $Version$.
|
||||
Watermark=watermark.xpm
|
||||
Watermark=watermark.png
|
||||
|
||||
[Dialog License]
|
||||
Show Dialog=TRUE
|
||||
|
|
|
@ -24,7 +24,10 @@ export::
|
|||
$(NSINSTALL) -D $(DIST)/branding
|
||||
cp $(addprefix $(srcdir)/, $(BROWSER_APP_FILES)) $(DIST)/branding/
|
||||
ifneq (,$(filter gtk gtk2,$(MOZ_WIDGET_TOOLKIT)))
|
||||
cp $(srcdir)/document.png $(DIST)/branding/document.png
|
||||
cp $(srcdir)/document.png $(DIST)/branding/document.png
|
||||
$(NSINSTALL) -D $(DIST)/install
|
||||
cp $(srcdir)/header.png $(DIST)/install/header.png
|
||||
cp $(srcdir)/watermark.png $(DIST)/install/watermark.png
|
||||
endif
|
||||
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
|
||||
cp $(srcdir)/firefox.icns $(DIST)/branding/firefox.icns
|
||||
|
|
Двоичный файл не отображается.
После Ширина: | Высота: | Размер: 8.8 KiB |
Двоичный файл не отображается.
После Ширина: | Высота: | Размер: 54 KiB |
|
@ -11,8 +11,8 @@ $exe_suffix = '';
|
|||
"mozilla-installer",
|
||||
"mozilla-installer-bin",
|
||||
"installer.ini",
|
||||
"watermark.xpm",
|
||||
"header.xpm"
|
||||
"watermark.png",
|
||||
"header.png"
|
||||
);
|
||||
@extra_ini_files = ();
|
||||
|
||||
|
|
|
@ -143,21 +143,26 @@ nsWelcomeDlg::Show(int aDirection)
|
|||
|
||||
GtkWidget *wmbox = gtk_event_box_new();
|
||||
if (mPixmap) {
|
||||
GdkPixmap *pm = gdk_pixmap_create_from_xpm(GDK_ROOT_PARENT(),
|
||||
NULL, NULL, mPixmap);
|
||||
GdkPixbuf *pb = gdk_pixbuf_new_from_file(mPixmap, NULL);
|
||||
if (pb) {
|
||||
GdkPixmap *pm = NULL;
|
||||
gdk_pixbuf_render_pixmap_and_mask(pb, &pm, NULL, 0);
|
||||
if (pm) {
|
||||
GtkStyle *newStyle = gtk_style_copy(gtk_widget_get_style(wmbox));
|
||||
newStyle->bg_pixmap[GTK_STATE_NORMAL] = pm;
|
||||
gtk_widget_set_style(wmbox, newStyle);
|
||||
|
||||
if (pm) {
|
||||
GtkStyle *newStyle = gtk_style_copy(gtk_widget_get_style(wmbox));
|
||||
newStyle->bg_pixmap[GTK_STATE_NORMAL] = pm;
|
||||
gtk_widget_set_style(wmbox, newStyle);
|
||||
// newStyle now owns the pixmap, so we don't unref it.
|
||||
g_object_unref(newStyle);
|
||||
|
||||
// newStyle now owns the pixmap, so we don't unref it.
|
||||
g_object_unref(newStyle);
|
||||
// Make the watermark box the width of the pixmap.
|
||||
gint width, height;
|
||||
gdk_drawable_get_size(pm, &width, &height);
|
||||
gtk_widget_set_size_request(wmbox, width, -1);
|
||||
}
|
||||
|
||||
// Make the watermark box the width of the pixmap.
|
||||
gint width, height;
|
||||
gdk_drawable_get_size(pm, &width, &height);
|
||||
gtk_widget_set_size_request(wmbox, width, -1);
|
||||
// We're done with rendering the pixbuf, so we can destroy it.
|
||||
gdk_pixbuf_unref(pb);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -185,19 +185,28 @@ nsXInstaller::RunWizard(int argc, char **argv)
|
|||
|
||||
gCtx->header = gtk_event_box_new();
|
||||
if (gCtx->opt->mHeaderPixmap) {
|
||||
GdkPixmap *pm = gdk_pixmap_create_from_xpm(GDK_ROOT_PARENT(),
|
||||
NULL, NULL,
|
||||
gCtx->opt->mHeaderPixmap);
|
||||
GdkPixbuf *pb = gdk_pixbuf_new_from_file(gCtx->opt->mHeaderPixmap, NULL);
|
||||
if (pb) {
|
||||
GdkPixmap *pm = NULL;
|
||||
gdk_pixbuf_render_pixmap_and_mask(pb, &pm, NULL, 0);
|
||||
if (pm) {
|
||||
GtkStyle *newStyle =
|
||||
gtk_style_copy(gtk_widget_get_style(gCtx->header));
|
||||
|
||||
if (pm) {
|
||||
GtkStyle *newStyle =
|
||||
gtk_style_copy(gtk_widget_get_style(gCtx->header));
|
||||
newStyle->bg_pixmap[GTK_STATE_NORMAL] = pm;
|
||||
gtk_widget_set_style(gCtx->header, newStyle);
|
||||
|
||||
newStyle->bg_pixmap[GTK_STATE_NORMAL] = pm;
|
||||
gtk_widget_set_style(gCtx->header, newStyle);
|
||||
// newStyle now owns the pixmap, so we don't unref it.
|
||||
g_object_unref(newStyle);
|
||||
|
||||
// newStyle now owns the pixmap, so we don't unref it.
|
||||
g_object_unref(newStyle);
|
||||
// Make the initial window width be as wide as the header.
|
||||
gint width, height;
|
||||
gdk_drawable_get_size(pm, &width, &height);
|
||||
gtk_window_set_default_size(GTK_WINDOW(gCtx->window), width, -1);
|
||||
}
|
||||
|
||||
// We're done with rendering the pixbuf, so destroy it.
|
||||
gdk_pixbuf_unref(pb);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче