KDE 4.5 PyKDE API Reference

- KDE's Python API

# UiInterface Class Reference

`from PyKDE4.kio import *`

Namespace: KIO.FileUndoManager

## Detailed Description

Interface for the gui handling of FileUndoManager. This includes three events currently: - error when undoing a job - confirm deletion before undoing a copy job - confirm deletion when the copied file has been modified afterwards

By default UiInterface shows message boxes in all three cases; applications can reimplement this interface to provide different user interfaces.

## Methods
| __init__ (self)
bool | confirmDeletion (self, KUrl.List files)
bool | copiedFileWasModified (self, KUrl src, KUrl dest, KDateTime srcTime, KDateTime destTime)
| jobError (self, KIO.Job job)
QWidget | parentWidget (self)
| setParentWidget (self, QWidget parentWidget)
| setShowProgressInfo (self, bool b)
bool | showProgressInfo (self)
| virtual_hook (self, int id, void data)

## Method Documentation

__init__ | ( |  | self ) |

bool confirmDeletion | ( | self, |
|  | KUrl.List | files
| ) |  |  |

Called when we are about to remove those files. Return true if we should proceed with deleting them.

bool copiedFileWasModified | ( | self, |
|  | KUrl | src,
|  | KUrl | dest,
|  | KDateTime | srcTime,
|  | KDateTime | destTime
| ) |  |  |

Called when dest was modified since it was copied from src. Note that this is called after confirmDeletion. Return true if we should proceed with deleting dest.

jobError | ( | self, |
|  | KIO.Job | job
| ) |  |  |

Called when an undo job errors; default implementation displays a message box.

QWidget parentWidget | ( |  | self ) |

Returns:
  the parent widget passed to the last call to undo(parentWidget), or 0.

setParentWidget | ( | self, |
|  | QWidget | parentWidget
| ) |  |  |

Sets the parent widget to use for message boxes.

setShowProgressInfo | ( | self, |
|  | bool | b
| ) |  |  |

Sets whether to show progress info when running the KIO jobs for undoing.

bool showProgressInfo | ( |  | self ) |

Returns:
  whether progress info dialogs are shown while undoing.

virtual_hook | ( | self, |
|  | int | id,
|  | void | data
| ) |  |  |

\internal, for future extensions