diff --git a/mobile/feed.php b/mobile/feed.php
index 966e1b440..bd5804cca 100644
--- a/mobile/feed.php
+++ b/mobile/feed.php
@@ -24,7 +24,8 @@
$cat_id = db_escape_string($_REQUEST["cat"]);
$offset = (int) db_escape_string($_REQUEST["skip"]);
$search = db_escape_string($_REQUEST["search"]);
+ $is_cat = (bool) db_escape_string($_REQUEST["is_cat"]);
- render_headlines_list($link, $feed_id, $cat_id, $offset, $search);
+ render_headlines_list($link, $feed_id, $cat_id, $offset, $search, $is_cat);
?>
diff --git a/mobile/functions.php b/mobile/functions.php
index 7f5dd5c6f..68530cf8f 100644
--- a/mobile/functions.php
+++ b/mobile/functions.php
@@ -100,9 +100,9 @@
}
- function render_category($link, $cat_id) {
+ function render_category($link, $cat_id, $offset) {
$owner_uid = $_SESSION["uid"];
-
+
if ($cat_id >= 0) {
if ($cat_id != 0) {
@@ -227,10 +227,11 @@
function render_categories_list($link) {
$owner_uid = $_SESSION["uid"];
-
+
+ $cat_browse = mobile_get_pref($link, "BROWSE_CATS");
+
print '
">
diff --git a/sanity_check.php b/sanity_check.php
index d70445e02..ad93b0cc7 100644
--- a/sanity_check.php
+++ b/sanity_check.php
@@ -2,7 +2,7 @@
require_once "functions.php";
define('EXPECTED_CONFIG_VERSION', 21);
- define('SCHEMA_VERSION', 78);
+ define('SCHEMA_VERSION', 79);
if (!file_exists("config.php")) {
print "
Fatal Error: You forgot to copy
diff --git a/schema/ttrss_schema_mysql.sql b/schema/ttrss_schema_mysql.sql
index 7e9a5e761..c1d080e2e 100644
--- a/schema/ttrss_schema_mysql.sql
+++ b/schema/ttrss_schema_mysql.sql
@@ -258,7 +258,7 @@ create table ttrss_tags (id integer primary key auto_increment,
create table ttrss_version (schema_version int not null) TYPE=InnoDB DEFAULT CHARSET=UTF8;
-insert into ttrss_version values (78);
+insert into ttrss_version values (79);
create table ttrss_enclosures (id integer primary key auto_increment,
content_url text not null,
@@ -389,6 +389,8 @@ insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id,help_
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id,help_text) values('SORT_HEADLINES_BY_FEED_DATE', 1, 'true', 'Sort headlines by feed date',3, 'Use feed-specified date to sort headlines instead of local import date.');
+insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_MOBILE_BROWSE_CATS', 1, 'true', '', 1);
+
create table ttrss_user_prefs (
owner_uid integer not null,
pref_name varchar(250),
diff --git a/schema/ttrss_schema_pgsql.sql b/schema/ttrss_schema_pgsql.sql
index 414fc28ea..e0973bdcc 100644
--- a/schema/ttrss_schema_pgsql.sql
+++ b/schema/ttrss_schema_pgsql.sql
@@ -229,7 +229,7 @@ create index ttrss_tags_post_int_id_idx on ttrss_tags(post_int_id);
create table ttrss_version (schema_version int not null);
-insert into ttrss_version values (78);
+insert into ttrss_version values (79);
create table ttrss_enclosures (id serial not null primary key,
content_url text not null,
@@ -353,6 +353,8 @@ insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id,help_
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id,help_text) values('USER_STYLESHEET', 2, '', 'Customize stylesheet', 2, 'Customize CSS stylesheet to your liking');
+insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_MOBILE_BROWSE_CATS', 1, 'true', '', 1);
+
create table ttrss_user_prefs (
owner_uid integer not null references ttrss_users(id) ON DELETE CASCADE,
pref_name varchar(250) not null references ttrss_prefs(pref_name) ON DELETE CASCADE,
diff --git a/schema/versions/mysql/79.sql b/schema/versions/mysql/79.sql
new file mode 100644
index 000000000..7e8c31d49
--- /dev/null
+++ b/schema/versions/mysql/79.sql
@@ -0,0 +1,7 @@
+begin;
+
+insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_MOBILE_BROWSE_CATS', 1, 'true', '', 1);
+
+update ttrss_version set schema_version = 79;
+
+commit;
diff --git a/schema/versions/pgsql/79.sql b/schema/versions/pgsql/79.sql
new file mode 100644
index 000000000..7e8c31d49
--- /dev/null
+++ b/schema/versions/pgsql/79.sql
@@ -0,0 +1,7 @@
+begin;
+
+insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_MOBILE_BROWSE_CATS', 1, 'true', '', 1);
+
+update ttrss_version set schema_version = 79;
+
+commit;