aboutsummaryrefslogtreecommitdiff
path: root/pyaggr3g470r/views/views.py
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2015-04-12 17:03:20 +0200
committerCédric Bonhomme <cedric@cedricbonhomme.org>2015-04-12 17:03:20 +0200
commit9a9b5c19d8c07026b104ed81838145454bfa9fc9 (patch)
tree054d348fd66b9c196545037077d6ac3f64b158c5 /pyaggr3g470r/views/views.py
parentMerged in jaesivsm/pyaggr3g470r (pull request #8) (diff)
downloadnewspipe-9a9b5c19d8c07026b104ed81838145454bfa9fc9.tar.gz
newspipe-9a9b5c19d8c07026b104ed81838145454bfa9fc9.tar.bz2
newspipe-9a9b5c19d8c07026b104ed81838145454bfa9fc9.zip
It is now possible to add a new feed from any page via a dropdown menu.
Diffstat (limited to 'pyaggr3g470r/views/views.py')
-rw-r--r--pyaggr3g470r/views/views.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/pyaggr3g470r/views/views.py b/pyaggr3g470r/views/views.py
index e06e1a9d..06b234cd 100644
--- a/pyaggr3g470r/views/views.py
+++ b/pyaggr3g470r/views/views.py
@@ -138,6 +138,16 @@ def get_timezone():
except:
return conf.TIME_ZONE["en"]
+@app.context_processor
+def inject_feed_form():
+ """
+ Injects the 'AddFeedForm' objects in all templates.
+
+ Context processors run before the template is rendered and have the
+ ability to inject new values into the template context.
+ """
+ return dict(create_feed_form=AddFeedForm())
+
#
# Views.
#
bgstack15