evince: allow overriding number of items shown in recent opened list
svn path=/nixpkgs/trunk/; revision=17314
This commit is contained in:
parent
cde0f366c2
commit
47a2c768f9
|
@ -3,7 +3,9 @@
|
|||
, libgnome, libgnomeui, scrollkeeper, libxslt
|
||||
, libglade, dbus, dbus_glib
|
||||
, poppler, libspectre, djvulibre, shared_mime_info
|
||||
, makeWrapper, which }:
|
||||
, makeWrapper, which
|
||||
, recentListSize ? null # 5 is not enough, allow passing a different number
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "evince-2.26.0";
|
||||
|
@ -28,6 +30,11 @@ stdenv.mkDerivation rec {
|
|||
# Do not update Scrollkeeper's database (GNOME's help system).
|
||||
+ "--disable-scrollkeeper";
|
||||
|
||||
postUnpack = if recentListSize != null then ''
|
||||
sed -i 's/\(gtk_recent_chooser_set_limit .*\)5)/\1${builtins.toString recentListSize})/' */shell/ev-open-recent-action.c
|
||||
sed -i 's/\(if (++n_items == \)5\(.*\)/\1${builtins.toString recentListSize}\2/' */shell/ev-window.c
|
||||
'' else "";
|
||||
|
||||
postInstall = ''
|
||||
# Tell Glib/GIO about the MIME info directory, which is used
|
||||
# by `g_file_info_get_content_type ()'.
|
||||
|
|
|
@ -6573,7 +6573,7 @@ let
|
|||
# The forthcoming GNU Emacs 23 used to be referred to as `emacsUnicode' here.
|
||||
emacsUnicode = emacs23;
|
||||
|
||||
evince = import ../applications/misc/evince {
|
||||
evince = makeOverridable (import ../applications/misc/evince) {
|
||||
inherit fetchurl stdenv perl perlXMLParser gettext intltool
|
||||
pkgconfig poppler libspectre djvulibre libxslt
|
||||
dbus dbus_glib shared_mime_info which makeWrapper;
|
||||
|
|
Loading…
Reference in New Issue