Skip to content

Commit

Permalink
Spreadsheet: show number of filtered rows only when necessary
Browse files Browse the repository at this point in the history
  • Loading branch information
JacquesLucke committed Mar 15, 2021
1 parent c82f65b commit e7f59e6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions source/blender/editors/space_spreadsheet/space_spreadsheet.cc
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,11 @@ static void spreadsheet_footer_region_draw(const bContext *C, ARegion *region)
SpaceSpreadsheet *sspreadsheet = CTX_wm_space_spreadsheet(C);
SpaceSpreadsheet_Runtime *runtime = sspreadsheet->runtime;
std::stringstream ss;
ss << "Rows: " << runtime->visible_rows << " / " << runtime->tot_rows
<< " | Columns: " << runtime->tot_columns;
ss << "Rows: ";
if (runtime->visible_rows != runtime->tot_rows) {
ss << runtime->visible_rows << " / ";
}
ss << runtime->tot_rows << " | Columns: " << runtime->tot_columns;
std::string stats_str = ss.str();

UI_ThemeClearColor(TH_BACK);
Expand Down

0 comments on commit e7f59e6

Please sign in to comment.