Skip to content

Commit

Permalink
add 1.8.1 comaptible
Browse files Browse the repository at this point in the history
  • Loading branch information
martec committed Nov 2, 2014
1 parent 2308c01 commit 1da131c
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 8 deletions.
2 changes: 2 additions & 0 deletions inc/languages/english/admin/config_quickadveditor.lang.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
$l['quickadveditor_qedit_desc'] = 'Set to no if you do not want to show the sceditor in quick edit.';
$l['quickadveditor_autosave_title'] = 'Auto Save Draft Feature';
$l['quickadveditor_autosave_desc'] = 'Set to no if you do not want enable auto save draft feature in quick reply.';
$l['quickadveditor_savetime_title'] = 'Auto Save Draft: Time interval';
$l['quickadveditor_savetime_desc'] = 'Interval the time in second. Default 15 second. Interval lower than default value is not recommended.';
$l['quickadveditor_canonical_title'] = 'Canonical Link Feature';
$l['quickadveditor_canonical_desc'] = 'Set to no if you do not want enable canonical link feature, this feature required by Auto Save Draft. If you use canonical link feature of google seo plugin, you can disable this feature.';
$l['quickadveditor_save_title'] = 'Language for save action';
Expand Down
26 changes: 18 additions & 8 deletions inc/plugins/quickadveditor.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ function quickadveditor_info ()
"website" => "",
"author" => "martec",
"authorsite" => "",
"version" => "5.5.2",
"version" => "5.6.0",
"guid" => "",
"compatibility" => "18*"
);
Expand Down Expand Up @@ -88,14 +88,24 @@ function quickadveditor_install()
'disporder' => '5',
'gid' => $groupid
));

$db->insert_query('settings', array(
'name' => 'quickadveditor_savetime',
'title' => $lang->quickadveditor_savetime_title,
'description' => $lang->quickadveditor_savetime_desc,
'optionscode' => 'text',
'value' => '15',
'disporder' => '6',
'gid' => $groupid
));

$db->insert_query('settings', array(
'name' => 'quickadveditor_canonicallink',
'title' => $lang->quickadveditor_canonical_title,
'description' => $lang->quickadveditor_canonical_desc,
'optionscode' => 'onoff',
'value' => '1',
'disporder' => '6',
'disporder' => '7',
'gid' => $groupid
));

Expand All @@ -105,7 +115,7 @@ function quickadveditor_install()
'description' => $lang->quickadveditor_save_desc,
'optionscode' => 'text',
'value' => $lang->quickadveditor_save_default,
'disporder' => '7',
'disporder' => '8',
'gid' => $groupid
));

Expand All @@ -115,7 +125,7 @@ function quickadveditor_install()
'description' => $lang->quickadveditor_restor_desc,
'optionscode' => 'text',
'value' => $lang->quickadveditor_restor_default,
'disporder' => '8',
'disporder' => '9',
'gid' => $groupid
));

Expand Down Expand Up @@ -160,7 +170,7 @@ function quickadveditor_activate()
var partialmode = {\$mybb->settings[\'partialmode\']},
opt_editor = {
plugins: \"bbcode\",
style: \"{\$mybb->asset_url}/jscripts/sceditor/jquery.sceditor.mybb.css\",
style: \"{\$mybb->asset_url}/jscripts/sceditor/textarea_styles/jquery.sceditor.{\$theme[\'editortheme\']}\",
rtl: {\$lang->settings[\'rtl\']},
locale: \"mybblang\",
enablePasteFiltering: true,
Expand Down Expand Up @@ -245,7 +255,7 @@ function quickadveditor_activate()
}
}
}
},15000);
},{\$mybb->settings[\'quickadveditor_savetime\']}*1000);
setTimeout(function() {
restitem = localStorage.getItem(link_can + \'quickreply\');
Expand Down Expand Up @@ -306,7 +316,7 @@ function quickadveditor_activate()
var partialmode = {\$mybb->settings[\'partialmode\']},
opt_editor = {
plugins: \"bbcode\",
style: \"{\$mybb->asset_url}/jscripts/sceditor/jquery.sceditor.mybb.css\",
style: \"{\$mybb->asset_url}/jscripts/sceditor/textarea_styles/jquery.sceditor.{\$theme[\'editortheme\']}\",
rtl: {\$lang->settings[\'rtl\']},
locale: \"mybblang\",
enablePasteFiltering: true,
Expand Down Expand Up @@ -362,7 +372,7 @@ function quickadveditor_activate()
}
}
}
},15000);
},{\$mybb->settings[\'quickadveditor_savetime\']}*1000);
setTimeout(function() {
restitem = localStorage.getItem(location.href + \'quickreply\');
Expand Down

0 comments on commit 1da131c

Please sign in to comment.