Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
KDE Pim
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Unmaintained
KDE Pim
Commits
c9d4b220
Commit
c9d4b220
authored
Jan 31, 2013
by
Laurent Montel
😁
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor optimization
parent
349adb01
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
blogilo/src/mainwindow.cpp
blogilo/src/mainwindow.cpp
+4
-4
No files found.
blogilo/src/mainwindow.cpp
View file @
c9d4b220
...
...
@@ -138,7 +138,7 @@ bool MainWindow::queryExit()
writeConfigs
();
if
(
!
DBMan
::
self
()
->
clearTempEntries
()
)
kDebug
()
<<
"Could not erase temp_post table: "
<<
DBMan
::
self
()
->
lastErrorText
();
int
count
=
tabPosts
->
count
();
const
int
count
=
tabPosts
->
count
();
if
(
count
>
0
)
{
toolbox
->
getFieldsValue
(
activePost
->
currentPost
());
for
(
int
i
=
0
;
i
<
count
;
++
i
)
{
...
...
@@ -224,7 +224,7 @@ void MainWindow::setCurrentBlog( int blog_id )
// actionCollection()->action("publish_post")->setEnabled( false );
return
;
}
int
count
=
blogs
->
items
().
count
();
const
int
count
=
blogs
->
items
().
count
();
for
(
int
i
=
0
;
i
<
count
;
++
i
)
{
if
(
blogs
->
action
(
i
)
->
data
().
toInt
()
==
blog_id
)
{
blogs
->
setCurrentItem
(
i
);
...
...
@@ -262,7 +262,7 @@ void MainWindow::slotCreateNewPost()
tabPosts
->
setCurrentWidget
(
createPostEntry
(
mCurrentBlogId
,
BilboPost
())
);
if
(
mCurrentBlogId
==
-
1
)
{
if
(
blogs
->
items
().
count
()
>
0
)
{
if
(
!
blogs
->
items
().
isEmpty
()
)
{
blogs
->
setCurrentItem
(
0
);
currentBlogChanged
(
blogs
->
action
(
0
)
);
}
...
...
@@ -366,7 +366,7 @@ void MainWindow::slotBlogEdited( const BilboBlog &blog )
void
MainWindow
::
slotBlogRemoved
(
int
blog_id
)
{
int
count
=
blogs
->
actions
().
count
();
const
int
count
=
blogs
->
actions
().
count
();
for
(
int
i
=
0
;
i
<
count
;
++
i
){
if
(
blogs
->
action
(
i
)
->
data
().
toInt
()
==
blog_id
)
{
if
(
blogs
->
currentItem
()
==
i
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment