Index: trunk/src/VBox/Frontends/VirtualBox/src/globals/UICustomFileSystemModel.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/globals/UICustomFileSystemModel.cpp	(revision 76705)
+++ trunk/src/VBox/Frontends/VirtualBox/src/globals/UICustomFileSystemModel.cpp	(revision 76707)
@@ -98,4 +98,15 @@
 }
 
+void UICustomFileSystemItem::removeChild(UICustomFileSystemItem *pItem)
+{
+    int iIndex = m_childItems.indexOf(pItem);
+    if (iIndex == -1 || iIndex > m_childItems.size())
+        return;
+    m_childItems.removeAt(iIndex);
+    m_childMap.remove(pItem->name());
+    delete pItem;
+    pItem = 0;
+}
+
 int UICustomFileSystemItem::columnCount() const
 {
@@ -574,4 +585,13 @@
 }
 
+void UICustomFileSystemModel::deleteItem(UICustomFileSystemItem* pItem)
+{
+    if (!pItem)
+        return;
+    UICustomFileSystemItem *pParent = pItem->parentItem();
+    if (pParent)
+        pParent->removeChild(pItem);
+}
+
 void UICustomFileSystemModel::initializeTree()
 {
Index: trunk/src/VBox/Frontends/VirtualBox/src/globals/UICustomFileSystemModel.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/globals/UICustomFileSystemModel.h	(revision 76705)
+++ trunk/src/VBox/Frontends/VirtualBox/src/globals/UICustomFileSystemModel.h	(revision 76707)
@@ -59,4 +59,6 @@
     int childCount() const;
     QList<const UICustomFileSystemItem*> children() const;
+    /** Removes the item from the list of children and !!DELETES!! the item. */
+    void removeChild(UICustomFileSystemItem *pItem);
     int columnCount() const;
     QVariant data(int column) const;
@@ -188,4 +190,5 @@
     void           setShowHumanReadableSizes(bool fShowHumanReadableSizes);
     bool           showHumanReadableSizes() const;
+    void           deleteItem(UICustomFileSystemItem* pItem);
     UICustomFileSystemItem* rootItem();
     const UICustomFileSystemItem* rootItem() const;
Index: trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.cpp	(revision 76705)
+++ trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.cpp	(revision 76707)
@@ -137,5 +137,5 @@
             pAddedItem->setIsSymLinkToADirectory(QFileInfo(fileInfo.symLinkTarget()).isDir());
         }
-        m_entryList << createAnIsoEntry(pAddedItem);
+        createAnIsoEntry(pAddedItem);
     }
     if (m_pTableProxyModel)
@@ -148,20 +148,30 @@
 }
 
-QString UIVisoContentBrowser::createAnIsoEntry(UICustomFileSystemItem *pItem)
-{
-    QString strEntry;
+void UIVisoContentBrowser::createAnIsoEntry(UICustomFileSystemItem *pItem, bool bRemove /* = false */)
+{
     if (!pItem)
-        return strEntry;
-    if (pItem->data(UICustomFileSystemModelColumn_Path).toString().isEmpty() ||
-        pItem->data(UICustomFileSystemModelColumn_LocalPath).toString().isEmpty())
-        return strEntry;
-    strEntry = QString("%1=%2").arg(pItem->data(UICustomFileSystemModelColumn_Path).toString()).
-        arg(pItem->data(UICustomFileSystemModelColumn_LocalPath).toString());
-    return strEntry;
+        return;
+    if (pItem->data(UICustomFileSystemModelColumn_Path).toString().isEmpty())
+        return;
+
+    if (!bRemove && pItem->data(UICustomFileSystemModelColumn_LocalPath).toString().isEmpty())
+        return;
+    if (!bRemove)
+        m_entryMap.insert(pItem->data(UICustomFileSystemModelColumn_Path).toString(),
+                          pItem->data(UICustomFileSystemModelColumn_LocalPath).toString());
+    else
+        m_entryMap.insert(pItem->data(UICustomFileSystemModelColumn_Path).toString(),
+                          ":remove:");
 }
 
 QStringList UIVisoContentBrowser::entryList()
 {
-    return m_entryList;
+    QStringList entryList;
+    for (QMap<QString, QString>::const_iterator iterator = m_entryMap.begin(); iterator != m_entryMap.end(); ++iterator)
+    {
+        QString strEntry = QString("%1=%2").arg(iterator.key()).arg(iterator.value());
+        entryList << strEntry;
+    }
+    return entryList;
 }
 
@@ -234,5 +244,4 @@
     }
 
-
     UICustomFileSystemItem* pAddedItem = new UICustomFileSystemItem(strNewDirectoryName, pParentItem,
                                                                     KFsObjType_Directory);
@@ -246,4 +255,45 @@
 }
 
+void UIVisoContentBrowser::sltHandleRemoveItems()
+{
+    QVector<UICustomFileSystemItem*> selectedItems = tableSelectedItems();
+    foreach(UICustomFileSystemItem *pItem, selectedItems)
+    {
+        if (!pItem)
+            continue;
+        /* If the item is a directory the remove the item from iso entry list: */
+        if (pItem->type() == KFsObjType_Directory)
+        {
+            for (QMap<QString, QString>::iterator iterator = m_entryMap.begin(); iterator != m_entryMap.end(); )
+            {
+                QString strIsoPath = pItem->data(UICustomFileSystemModelColumn_Path).toString();
+                if (strIsoPath.isEmpty())
+                    continue;
+                if (iterator.key().startsWith(strIsoPath, Qt::CaseInsensitive))
+                    iterator = m_entryMap.erase(iterator);
+                else
+                    ++iterator;
+            }
+        }
+        /* Else mark it as "removed" in the viso file entry list: */
+        else
+        {
+            createAnIsoEntry(pItem, true /* bool bRemove */);
+        }
+    }
+    foreach(UICustomFileSystemItem *pItem, selectedItems)
+    {
+        if (!pItem)
+            continue;
+        /* Remove the item from the m_pModel: */
+        if (m_pModel)
+            m_pModel->deleteItem(pItem);
+        if (m_pTreeProxyModel)
+            m_pTreeProxyModel->invalidate();
+        if (m_pTableProxyModel)
+            m_pTableProxyModel->invalidate();
+    }
+}
+
 void UIVisoContentBrowser::prepareObjects()
 {
@@ -269,7 +319,6 @@
     {
         m_pTreeView->setModel(m_pTreeProxyModel);
-        // m_pTreeView->setRootIndex(m_pProxyModel->mapFromSource(m_pModel->rootIndex()));
         m_pTreeView->setCurrentIndex(m_pTreeProxyModel->mapFromSource(m_pModel->rootIndex()));
-
+        m_pTreeView->setEditTriggers(QAbstractItemView::NoEditTriggers);
         /* Show only the 0th column that is "name': */
         m_pTreeView->hideColumn(UICustomFileSystemModelColumn_Owner);
@@ -317,4 +366,11 @@
         connect(m_pModel, &UICustomFileSystemModel::sigItemRenamed,
                 this, &UIVisoContentBrowser::sltHandleItemRenameAttempt);
+    if (m_pAddRemoveButton)
+        connect(m_pAddRemoveButton, &QIToolButton::clicked,
+                this, &UIVisoContentBrowser::sltHandleRemoveItems);
+    if (m_pTableView->selectionModel())
+        connect(m_pTableView->selectionModel(), &QItemSelectionModel::selectionChanged,
+                this, &UIVisoContentBrowser::sltHandleTableSelectionChanged);
+
 }
 
@@ -553,7 +609,34 @@
 }
 
+void UIVisoContentBrowser::sltHandleTableSelectionChanged(const QItemSelection &selected, const QItemSelection &deselected)
+{
+    Q_UNUSED(deselected);
+    if (m_pAddRemoveButton)
+        m_pAddRemoveButton->setEnabled(!selected.isEmpty());
+}
+
 void UIVisoContentBrowser::reset()
 {
-    m_entryList.clear();
-}
+    m_entryMap.clear();
+}
+
+QVector<UICustomFileSystemItem*> UIVisoContentBrowser::tableSelectedItems()
+{
+    QVector<UICustomFileSystemItem*> selectedItems;
+    if (!m_pTableProxyModel)
+        return selectedItems;
+    QItemSelectionModel *selectionModel = m_pTableView->selectionModel();
+    if (!selectionModel || selectionModel->selectedIndexes().isEmpty())
+        return selectedItems;
+    QModelIndexList list = selectionModel->selectedIndexes();
+    foreach (QModelIndex index, list)
+    {
+        UICustomFileSystemItem *pItem =
+            static_cast<UICustomFileSystemItem*>(m_pTableProxyModel->mapToSource(index).internalPointer());
+        if (pItem)
+            selectedItems << pItem;
+    }
+    return selectedItems;
+}
+
 #include "UIVisoContentBrowser.moc"
Index: trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.h	(revision 76705)
+++ trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoContentBrowser.h	(revision 76707)
@@ -76,5 +76,6 @@
     void sltHandleCreateNewDirectory();
     void sltHandleItemRenameAttempt(UICustomFileSystemItem *pItem, QString strOldName, QString strNewName);
-
+    void sltHandleRemoveItems();
+    void sltHandleTableSelectionChanged(const QItemSelection &selected, const QItemSelection &deselected);
 
 private:
@@ -90,13 +91,22 @@
     void                    updateStartItemName();
     void                    renameFileObject(UICustomFileSystemItem *pItem);
-    QString                 createAnIsoEntry(UICustomFileSystemItem *pItem);
+    /** Creates and entry for pItem consisting of a map item (key is iso path and value is host file system path)
+     *  if @p bRemove is true then the value is the string ":remove:" which effectively removes the file object
+     *  from the iso image. */
+    void                    createAnIsoEntry(UICustomFileSystemItem *pItem, bool bRemove = false);
     void                    reset();
-
+    /** Returns a list of items which are currecntly selected
+     *  in the table view. */
+    QVector<UICustomFileSystemItem*> tableSelectedItems();
     UICustomFileSystemModel      *m_pModel;
     UICustomFileSystemProxyModel *m_pTableProxyModel;
     UIVisoContentTreeProxyModel  *m_pTreeProxyModel;
     QIToolButton                 *m_pNewDirectoryButton;
+    QIToolButton                 *m_pRenameButton;
     QString                       m_strVisoName;
-    QStringList                   m_entryList;
+    /** keys of m_entryMap are iso locations and values are
+     *  local location of file objects. these keys and values are
+     *  concatenated and passed to the client to create ad-hoc.viso entries. */
+    QMap<QString, QString>        m_entryMap;
 };
 
Index: trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoHostBrowser.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoHostBrowser.cpp	(revision 76705)
+++ trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoHostBrowser.cpp	(revision 76707)
@@ -160,6 +160,6 @@
 {
     Q_UNUSED(deselected);
-    Q_UNUSED(selected);
-    m_pAddRemoveButton->setEnabled(!selected.isEmpty());
+    if (m_pAddRemoveButton)
+        m_pAddRemoveButton->setEnabled(!selected.isEmpty());
 }
 
