"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/SearchPanel.cpp" between
xfe-1.42.tar.gz and xfe-1.43.tar.gz

About: Xfe (X File Explorer) is a file manager and browser (using the FOX toolkit).

SearchPanel.cpp  (xfe-1.42):SearchPanel.cpp  (xfe-1.43)
skipping to change at line 931 skipping to change at line 931
FXbool newstr = true; FXbool newstr = true;
for (int i = 0; i < OpenNum-1; i++) for (int i = 0; i < OpenNum-1; i++)
{ {
if (streq(OpenHistory[i], cmd.text())) if (streq(OpenHistory[i], cmd.text()))
{ {
newstr = false; newstr = false;
break; break;
} }
} }
// Restore original history order
opendialog->clearItems();
for (int i = 0; i < OpenNum; i++)
{
opendialog->appendItem(OpenHistory[i]);
}
// History limit reached // History limit reached
if (OpenNum > OPEN_HIST_SIZE) if (OpenNum > OPEN_HIST_SIZE)
{ {
OpenNum--; OpenNum--;
} }
// New string // New string
if (newstr) if (newstr)
{ {
// FIFO // FIFO
skipping to change at line 4318 skipping to change at line 4325
getApp()->endWaitCursor(); getApp()->endWaitCursor();
MessageBox::error(this, BOX_OK, _("Error"), "%s", text); MessageBox::error(this, BOX_OK, _("Error"), "%s", text);
return(0); return(0);
} }
getApp()->endWaitCursor(); getApp()->endWaitCursor();
// Get package name, or detect when the file isn't in a package // Get package name, or detect when the file isn't in a package
FXString str = text; FXString str = text;
if (pkg_format == DEB_PKG) // DEB based distribution if (pkg_format == DEB_PKG) // DEB based distribution
{ {
FXString substr = str.section(':', 1); int idx = str.find(" "); // Split output at first whitespa
if (substr.length()-2 == file.length()) // No other word than the file n ce
ame FXString pkgname = str.left(idx-1); // Remove trailing colon
FXString fname = str.right(str.length()-idx);
fname.trim(); // Remove leading space and trail
ing newline
if (streq(fname.text(), file.text())) // No other word than the file na
me
{ {
str = str.section(':', 0); // (plus ' ' at the beginning an d '\n' at the end) str = pkgname.text();
} }
else else
{ {
str = ""; str = "";
} }
} }
if (pkg_format == RPM_PKG) // RPM based distribution if (pkg_format == RPM_PKG) // RPM based distribution
{ {
if (str.find(' ') != -1) // Space character exists in the string if (str.find(' ') != -1) // Space character exists in the string
{ {
 End of changes. 3 change blocks. 
4 lines changed or deleted 16 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)