From fdd296757c6c6205dfbe460f99b5fcd8c1bb64db Mon Sep 17 00:00:00 2001 From: "joon.c.baek" Date: Tue, 12 Apr 2016 12:17:01 +0900 Subject: [PATCH] [SRADA-363]Trial apply to change RCP 4.0. (don't model changed) - refs & PatchCode : suprem.sec.samsung.net/jira/browse/SRADA-325 - Enabling Connection and Setting Dialog - + Patch :remove needless menubar from workbenchWindow. Change-Id: I42fe2f8a2106db75c6e32100116bafedf8cf0eb3 --- LICENSE.APLv2 | 0 LICENSE.BSD2c | 0 LICENSE.EPL | 0 LICENSE.LGPLv2.1 | 0 images/time_line_icon_UI_events.png | Bin images/time_line_icon_battery_usage.png | Bin images/time_line_icon_cpu_core.png | Bin images/time_line_icon_cpu_frequency.png | Bin images/time_line_icon_devices.png | Bin images/time_line_icon_electric_current.png | Bin images/time_line_icon_memory_allocation.png | Bin images/time_line_icon_memory_appusage.png | Bin images/time_line_icon_memory_process.png | Bin images/time_line_icon_memory_system.png | Bin org.tizen.dynamicanalyzer.appearance/.classpath | 2 +- .../.settings/org.eclipse.jdt.core.prefs | 6 +- .../META-INF/MANIFEST.MF | 2 +- .../appearance/DesignConstants.java | 0 .../dynamicanalyzer/resources/ColorResources.java | 11 +- .../dynamicanalyzer/resources/FontResources.java | 0 .../dynamicanalyzer/resources/ImageResources.java | 14 +- .../tizen/dynamicanalyzer/theme/DAThemeBlack.java | 0 .../tizen/dynamicanalyzer/theme/DAThemeWhite.java | 4 + .../widgets/da/base/DAAbstractText.java | 3 +- .../widgets/da/base/DASearchTextBox.java | 140 ++++++ .../dynamicanalyzer/widgets/da/base/DATextBox.java | 4 +- .../widgets/da/base/DATextCallbackEvent.java | 40 ++ .../widgets/da/base/DAValidTextBox.java | 23 +- .../widgets/da/view/DATabButton.java | 0 .../widgets/da/view/DATabComposite.java | 4 +- .../widgets/da/view/DAViewComposite.java | 4 +- .../theme/black/img/dialog_edit_chart_minus.png | Bin .../theme/black/img/dialog_edit_chart_plus.png | Bin .../theme/black/img/edit_chart_icon_Heap.png | Bin .../theme/black/img/edit_chart_icon_UI_events.png | Bin .../theme/black/img/edit_chart_icon_audio.png | Bin .../black/img/edit_chart_icon_battery_usage.png | Bin .../theme/black/img/edit_chart_icon_bluetooth.png | Bin .../theme/black/img/edit_chart_icon_brightness.png | Bin .../theme/black/img/edit_chart_icon_camera.png | Bin .../theme/black/img/edit_chart_icon_cpu.png | Bin .../theme/black/img/edit_chart_icon_cpu_core.png | Bin .../black/img/edit_chart_icon_cpu_frequency.png | Bin .../theme/black/img/edit_chart_icon_devices.png | Bin .../black/img/edit_chart_icon_electric_current.png | Bin .../theme/black/img/edit_chart_icon_fd_usage.png | Bin .../theme/black/img/edit_chart_icon_gps.png | Bin .../img/edit_chart_icon_memory_allocation (2).png | Bin .../img/edit_chart_icon_memory_allocation.png | Bin .../black/img/edit_chart_icon_memory_appusage.png | Bin .../black/img/edit_chart_icon_memory_process.png | Bin .../black/img/edit_chart_icon_memory_system.png | Bin .../theme/black/img/edit_chart_icon_read_write.png | Bin .../black/img/edit_chart_icon_read_write_01.png | Bin .../theme/black/img/edit_chart_icon_snapshot.png | Bin .../theme/black/img/edit_chart_icon_sound.png | Bin .../theme/black/img/edit_chart_icon_vibration.png | Bin .../theme/black/img/edit_chart_icon_wifi.png | Bin .../theme/black/img/fail_api.png | Bin .../theme/black/img/time_line_icon_UI_events.png | Bin .../black/img/time_line_icon_battery_usage.png | Bin .../theme/black/img/time_line_icon_cpu_core.png | Bin .../black/img/time_line_icon_cpu_frequency.png | Bin .../theme/black/img/time_line_icon_devices.png | Bin .../black/img/time_line_icon_electric_current.png | Bin .../black/img/time_line_icon_memory_allocation.png | Bin .../black/img/time_line_icon_memory_appusage.png | Bin .../black/img/time_line_icon_memory_process.png | Bin .../black/img/time_line_icon_memory_system.png | Bin .../theme/black/img/time_line_icon_traffic.png | Bin .../theme/white/img/btn_delete_filter_hover.png | Bin 0 -> 3209 bytes .../theme/white/img/btn_delete_filter_normal.png | Bin 0 -> 3041 bytes .../theme/white/img/btn_delete_filter_push.png | Bin 0 -> 3186 bytes .../theme/white/img/btn_title_dropdown_hover.png | Bin 0 -> 2874 bytes .../theme/white/img/btn_title_dropdown_normal.png | Bin 0 -> 2851 bytes .../theme/white/img/btn_title_dropdown_push.png | Bin 0 -> 2971 bytes .../theme/white/img/column_filter_hover.png | Bin 0 -> 2879 bytes .../theme/white/img/column_filter_normal.png | Bin 0 -> 2886 bytes .../theme/white/img/column_filter_push.png | Bin 0 -> 2872 bytes .../white/img/feature_template_hierarchyviewer.png | Bin 0 -> 4151 bytes .../theme/white/img/img_search_grey.png | Bin 0 -> 3013 bytes .../theme/white/img/toolbar_pause_disable.png | Bin .../theme/white/img/toolbar_pause_hover.png | Bin .../theme/white/img/toolbar_pause_nor.png | Bin .../theme/white/img/toolbar_pause_push.png | Bin .../theme/white/img/toolbar_play_disable.png | Bin .../theme/white/img/toolbar_play_hover.png | Bin .../theme/white/img/toolbar_play_nor.png | Bin .../theme/white/img/toolbar_play_push.png | Bin .../theme/white/img/toolbar_stop_disable.png | Bin .../theme/white/img/toolbar_stop_hover.png | Bin .../theme/white/img/toolbar_stop_nor.png | Bin .../theme/white/img/toolbar_stop_push.png | Bin .../theme/white/img/toolbar_time_bg.png | Bin org.tizen.dynamicanalyzer.common/.classpath | 2 +- .../.settings/org.eclipse.jdt.core.prefs | 6 +- .../META-INF/MANIFEST.MF | 2 +- .../tizen/dynamicanalyzer/model/Streamable.java | 0 .../org/tizen/dynamicanalyzer/util/ByteUtil.java | 0 .../tizen/dynamicanalyzer/util/UnsignedInt.java | 7 +- org.tizen.dynamicanalyzer.splash/plugin.properties | 2 +- org.tizen.dynamicanalyzer.widgets/.classpath | 2 +- .../.settings/org.eclipse.jdt.core.prefs | 7 +- .../META-INF/MANIFEST.MF | 2 +- .../widgets/button/DACustomButton.java | 0 .../widgets/chartBoard/DAChartBoard.java | 0 .../DAChartBoardHeightChangeableItem.java | 2 +- .../widgets/chartBoard/DAChartBoardItem.java | 0 .../widgets/chartBoard/DAChartBoardItemCell.java | 0 .../feature.properties | 2 +- .../feature.xml | 13 - org.tizen.dynamicanalyzer.workbench/.classpath | 14 +- .../.settings/org.eclipse.jdt.core.prefs | 15 +- .../Application.e4xmi | 11 + .../META-INF/MANIFEST.MF | 3 +- .../build.properties | 25 +- .../dynamic-analyzer/config/feature | 0 .../dynamic-analyzer/config/setting | 6 +- .../dynamic-analyzer/config/template | 3 +- .../dynamic-analyzer/tool/Shortcut.vbs | 0 .../dynamic-analyzer/tool/cpio.exe | Bin .../dynamic-analyzer/tool/dd.exe | Bin .../dynamic-analyzer/tool/debuginfo.bat | 0 .../dynamic-analyzer/tool/gzip.exe | Bin .../dynamic-analyzer/tool/libiconv2.dll | Bin .../dynamic-analyzer/tool/libintl3.dll | Bin .../dynamic-analyzer/tool/md5sum.exe | Bin .../dynamic-analyzer/tool/od.exe | Bin .../dynamic-analyzer/tool/rpm2cpio.bat | 0 .../dynamicanalyzer.product | 121 +++-- .../plugin.properties | 2 +- org.tizen.dynamicanalyzer.workbench/plugin.xml | 24 +- .../dynamicanalyzer/common/path/PathManager.java | 0 .../dynamicanalyzer/workbench/Application.java | 5 +- .../workbench/ApplicationActionBarAdvisor.java | 27 +- .../ApplicationWorkbenchWindowAdvisor.java | 10 +- .../dynamicanalyzer/workbench/LayoutManager.java | 57 +-- .../workbench/SingletonFocusManager.java | 4 - org.tizen.dynamicanalyzer/.classpath | 2 +- .../.settings/org.eclipse.jdt.core.prefs | 12 +- org.tizen.dynamicanalyzer/META-INF/MANIFEST.MF | 3 +- org.tizen.dynamicanalyzer/ecs/gen.sh | 0 .../dynamicanalyzer/common/AnalyzerManager.java | 0 .../common/AnalyzerShellCommands.java | 0 .../tizen/dynamicanalyzer/common/DALogExport.java | 0 .../org/tizen/dynamicanalyzer/common/DAResult.java | 0 .../communicator/BaseCommunicator.java | 12 + .../communicator/CommunicatorUtils.java | 10 +- .../communicator/DACommunicator.java | 16 +- .../communicator/DeviceManager.java | 0 .../communicator/SubCommunicator.java | 0 .../dynamicanalyzer/control/ApplistManager.java | 0 .../tizen/dynamicanalyzer/handlers/UIAction.java | 14 + .../listeners/AnalyzerPerspectiveListener.java | 0 .../dynamicanalyzer/model/FilterProperty.java | 56 +++ .../tizen/dynamicanalyzer/nl/AnalyzerLabels.java | 16 +- .../dynamicanalyzer/nl/AnalyzerLabels.properties | 27 +- .../tizen/dynamicanalyzer/nl/ConfigureLabels.java | 2 + .../dynamicanalyzer/nl/ConfigureLabels.properties | 2 + .../dynamicanalyzer/nl/GLPageLabels.properties | 2 +- .../tizen/dynamicanalyzer/nl/MemoryPageLabels.java | 2 +- .../dynamicanalyzer/nl/MemoryPageLabels.properties | 2 +- .../tizen/dynamicanalyzer/nl/SummaryLabels.java | 3 + .../dynamicanalyzer/nl/SummaryLabels.properties | 3 + .../dynamicanalyzer/nl/UserErrorWarningLabels.java | 0 .../nl/UserErrorWarningLabels.properties | 0 .../tizen/dynamicanalyzer/project/BinaryInfo.java | 0 .../dynamicanalyzer/project/DeviceStatusInfo.java | 0 .../org/tizen/dynamicanalyzer/project/Project.java | 0 .../tizen/dynamicanalyzer/protocol/Protocol.java | 11 +- .../protocol/p30/ApplicationInst30.java | 0 .../protocol/p30/FunctionInst30.java | 0 .../protocol/p30/LibraryInst30.java | 0 .../protocol/p30_uihv/Communicator30_UIHV.java | 158 ++++++ .../protocol/p30_uihv/ProtocolConfig30_UIHV.java | 179 +++++++ .../protocol/p30_uihv/ProtocolConstant30_UIHV.java | 54 ++ .../tizen/dynamicanalyzer/setting/FeatureData.java | 26 +- .../dynamicanalyzer/setting/SettingConstants.java | 23 +- .../setting/SettingDataManager.java | 26 +- .../tizen/dynamicanalyzer/setting/TargetData.java | 22 +- .../tizen/dynamicanalyzer/setting/Template.java | 4 +- .../dynamicanalyzer/setting/TemplateData.java | 18 +- .../setting/UILayoutDataManager.java | 13 +- .../swap/communicator/DataChannelThread.java | 0 .../dynamicanalyzer/swap/logparser/LogPackage.java | 0 .../dynamicanalyzer/swap/logparser/LogParser.java | 0 .../tizen/dynamicanalyzer/swap/logparser/Logs.java | 0 .../swap/logparser/MessageParser.java | 6 +- .../model/data/FunctionBodyInstrumentData.java | 9 +- .../dynamicanalyzer/swap/model/data/LogData.java | 8 +- .../swap/model/data/LogDataTimeComparator.java | 0 .../swap/model/data/MemoryMapData.java | 13 +- .../swap/model/data/ProcessAddInfoData.java | 4 +- .../swap/model/data/ProcessInfoData.java | 16 +- .../swap/model/data/ProfileData.java | 17 +- .../swap/model/data/SystemData.java | 35 ++ .../swap/model/data/UIHierarchyData.java | 91 ++-- .../hierarchy/HierarchyUIObjectProperties.java | 7 + .../model/data/hierarchy/edje/EdjeProperties.java | 5 + .../hierarchy/elementary/ElementaryProperties.java | 5 + .../elementary/ElmBackgroundProperties.java | 5 + .../hierarchy/elementary/ElmButtonProperties.java | 5 + .../hierarchy/elementary/ElmCheckProperties.java | 6 +- .../elementary/ElmColorselectorProperties.java | 6 +- .../elementary/ElmCtxpopupProperties.java | 6 +- .../elementary/ElmDatetimeProperties.java | 5 + .../hierarchy/elementary/ElmEntryProperties.java | 5 + .../hierarchy/elementary/ElmFlipProperties.java | 6 +- .../hierarchy/elementary/ElmGengridProperties.java | 23 +- .../hierarchy/elementary/ElmGenlistProperties.java | 6 +- .../hierarchy/elementary/ElmGlviewProperties.java | 14 +- .../hierarchy/elementary/ElmIconProperties.java | 5 + .../hierarchy/elementary/ElmImageProperties.java | 6 +- .../hierarchy/elementary/ElmIndexProperties.java | 6 +- .../hierarchy/elementary/ElmLabelProperties.java | 14 +- .../hierarchy/elementary/ElmListProperties.java | 24 +- .../hierarchy/elementary/ElmMapProperties.java | 6 +- .../hierarchy/elementary/ElmNotifyProperties.java | 6 +- .../hierarchy/elementary/ElmPanelProperties.java | 5 + .../hierarchy/elementary/ElmPhotoProperties.java | 25 +- .../elementary/ElmPhotocamProperties.java | 6 +- .../hierarchy/elementary/ElmPopupProperties.java | 5 + .../elementary/ElmProgressbarProperties.java | 5 + .../hierarchy/elementary/ElmRadioProperties.java | 5 + .../elementary/ElmSegmentcontrolProperties.java | 5 + .../hierarchy/elementary/ElmSliderProperties.java | 5 + .../hierarchy/elementary/ElmSpinnerProperties.java | 5 + .../hierarchy/elementary/ElmToolbarProperties.java | 5 + .../hierarchy/elementary/ElmTooltipProperties.java | 5 + .../hierarchy/elementary/ElmWinProperties.java | 15 +- .../data/hierarchy/evas/EvasBoxProperties.java | 5 + .../data/hierarchy/evas/EvasGridProperties.java | 5 + .../data/hierarchy/evas/EvasImageProperties.java | 28 +- .../data/hierarchy/evas/EvasLineProperties.java | 5 + .../model/data/hierarchy/evas/EvasProperties.java | 5 + .../data/hierarchy/evas/EvasTableProperties.java | 5 + .../data/hierarchy/evas/EvasTextProperties.java | 5 + .../hierarchy/evas/EvasTextblockProperties.java | 5 + .../hierarchy/evas/EvasTextgridProperties.java | 5 + .../swap/platform/ui/SettingSaveTable.java | 2 +- .../ui/common/TimeLineChartKeyListener.java | 0 .../explorer/DAFileExplorerEmptyCellRenderer.java | 0 .../dynamicanalyzer/ui/file/FileApiListTable.java | 245 ++++++--- .../dynamicanalyzer/ui/file/FileApiListView.java | 6 +- .../ui/file/FileDetailInfoView.java | 2 +- .../tizen/dynamicanalyzer/ui/file/FilePage.java | 0 .../ui/file/data/FileAccessorDB.java | 4 +- .../dynamicanalyzer/ui/file/data/FileApiDB.java | 11 +- .../ui/file/manager/FileDataMaker.java | 2 +- .../ui/hierarchy/HierarchyPage.java | 0 .../ui/hierarchy/tree/HierarchyTreeView.java | 3 +- .../hierarchy/tree/tool/HierarchyTreeExporter.java | 1 + .../ui/info/callstack/CallstackTable.java | 6 + .../ui/info/callstack/CallstackView.java | 1 + .../dynamicanalyzer/ui/info/score/ScoreView.java | 2 +- .../ui/info/screenshot/ImageViewer.java | 0 .../ui/interactive/InteractivePage.java | 0 .../ui/interactive/table/InteractiveTable.java | 37 +- .../table/InteractiveTableCellRenderer.java | 0 .../ui/interactive/table/InteractiveTableView.java | 7 +- .../ui/kernel/ContextSwitchingChartView.java | 0 .../dynamicanalyzer/ui/kernel/KernelListTable.java | 2 +- .../dynamicanalyzer/ui/kernel/KernelPage.java | 0 .../ui/kernel/data/KernelDataMaker.java | 0 .../ui/memory/MemoryAllocationTraceTableView.java | 0 .../dynamicanalyzer/ui/memory/MemoryChartView.java | 0 .../ui/memory/MemoryDetailsTableView.java | 4 +- .../dynamicanalyzer/ui/memory/MemoryMapView.java | 6 +- .../dynamicanalyzer/ui/memory/MemoryPage.java | 0 .../ui/memory/MemoryStatisticsTableView.java | 0 .../ui/memory/chart/HeapMemoryChart.java | 0 .../ui/memory/chart/MemoryChart.java | 0 .../ui/memory/chart/MemoryChartBoard.java | 0 .../ui/memory/chart/ProcessMemoryChart.java | 0 .../ui/memory/chart/SystemMemoryChart.java | 0 .../ui/memory/data/AllocateDBTable.java | 0 .../ui/memory/data/FreeDBTable.java | 0 .../ui/memory/data/MemoryDataManager.java | 378 +++++++------- .../ui/memory/data/ProcessMemoryDBTable.java | 0 .../ui/memory/data/SystemMemoryDBTable.java | 0 .../memory/table/MemoryAllocationTraceTable.java | 0 .../ui/memory/table/MemoryDetailsTable.java | 7 +- .../ui/memory/table/MemoryMapTable.java | 18 +- .../ui/memory/table/MemoryStatisticsTable.java | 168 +++---- .../dynamicanalyzer/ui/network/NetworkChart.java | 44 +- .../dynamicanalyzer/ui/network/NetworkPage.java | 0 .../dynamicanalyzer/ui/network/NetworkTable.java | 237 ++++++--- .../ui/network/NetworkTableView.java | 35 +- .../ui/network/data/NetworkAPIDBManager.java | 17 +- .../ui/network/data/NetworkDataManager.java | 12 + .../tizen/dynamicanalyzer/ui/opengl/GLPage.java | 20 +- .../ui/opengl/chart/GLChartView.java | 0 .../ui/opengl/data/DB/GLAPIDBTableManager.java | 33 +- .../ui/opengl/data/GLDataManager.java | 9 +- .../ui/opengl/table/api/GLAPIListView.java | 7 +- .../ui/opengl/table/api/GLAPITable.java | 107 +++- .../ui/opengl/table/state/GLContextTable.java | 2 +- .../ui/opengl/table/state/GLContextTableView.java | 11 +- .../ui/opengl/table/state/GLProgramTable.java | 39 +- .../ui/opengl/table/state/GLProgramTableView.java | 7 +- .../ui/opengl/table/state/GLRedundantTable.java | 1 + .../opengl/table/state/GLRedundantTableView.java | 11 +- .../ui/opengl/table/state/GLStatisticsTable.java | 1 + .../opengl/table/state/GLStatisticsTableView.java | 11 +- .../ui/opengl/table/state/GLTextureTable.java | 73 ++- .../ui/opengl/table/state/GLTextureTableView.java | 6 +- .../tizen/dynamicanalyzer/ui/page/BaseView.java | 96 +++- .../ui/page/ScreenshotTabComposite.java | 0 .../tizen/dynamicanalyzer/ui/range/RangePage.java | 0 .../dynamicanalyzer/ui/summary/SummaryPage.java | 0 .../ui/summary/failed/FailedApiDataMaker.java | 74 ++- .../ui/summary/failed/FailedApiListView.java | 7 +- .../ui/summary/failed/FailedApiTable.java | 194 ++++++-- .../ui/summary/failed/FailedData.java | 0 .../ui/summary/leaks/LeakDataMaker.java | 107 +--- .../ui/summary/leaks/LeakTable.java | 305 +++++++----- .../dynamicanalyzer/ui/summary/leaks/LeakView.java | 6 +- .../FunctionUsageProfilingTableCellRenderer.java | 0 .../profiling/FunctionUsageProfilingView.java | 2 +- .../ui/summary/profiling/ProfilingTable.java | 88 +++- .../ui/summary/warning/WarningListView.java | 6 +- .../ui/summary/warning/WarningTable.java | 58 ++- .../ui/thread/ThreadAPIListTable.java | 203 +++++++- .../ui/thread/ThreadAPIListView.java | 8 +- .../dynamicanalyzer/ui/thread/ThreadPage.java | 0 .../ui/thread/chart/ThreadChartView.java | 0 .../dynamicanalyzer/ui/timeline/TimelinePage.java | 0 .../ui/timeline/calltrace/CallTraceTable.java | 1 + .../ui/timeline/chart/UserCustomChart.java | 0 .../ui/timeline/common/AddChartMenuComposite.java | 0 .../ui/timeline/common/TimelineConstants.java | 0 .../ui/timeline/logparser/CustomLogParser.java | 0 .../ui/timeline/uievent/UIEventListDialog.java | 1 + .../UIEventListDialogTableCellRenderer.java | 0 .../dynamicanalyzer/ui/toolbar/AboutDialog.java | 176 +++---- .../dynamicanalyzer/ui/toolbar/LicenseDialog.java | 2 +- .../dynamicanalyzer/ui/toolbar/SaveAsDialog.java | 0 .../tizen/dynamicanalyzer/ui/toolbar/Toolbar.java | 0 .../ui/toolbar/opentrace/OpenTraceDialog.java | 0 .../ui/toolbar/opentrace/SaveFilesTable.java | 1 + .../toolbar/replayEditor/RepalyEditSaveDialog.java | 0 .../replayEditor/ReplayEditScreenshotTable.java | 1 + .../ReplayEditScreenshotTableCellRenderer.java | 0 .../ui/toolbar/replayEditor/ReplayEditTable.java | 1 + .../ui/toolbar/setting/FeatureDialog.java | 31 +- .../setting/FeatureDialogFeaturesTable.java | 97 ++-- ...FeatureDialogFeaturesTreeTableCellRenderer.java | 6 +- ...atureDialogFeaturesTreeTableToggleRenderer.java | 67 +-- .../ui/toolbar/setting/SettingDialog.java | 4 +- .../ui/toolbar/setting/SettingDialogManager.java | 46 +- .../toolbar/setting/SettingDialogOptionPage.java | 3 - .../toolbar/setting/SettingDialogTemplatePage.java | 120 +++-- .../ui/toolbar/setting/WelcomeDialog.java | 1 - .../dynamicanalyzer/ui/userinterface/UIPage.java | 0 .../userinterface/control/UIControlListTable.java | 1 + .../profiling/UIFunctionProfilingTable.java | 1 + .../ui/userinterface/scene/UISceneListTable.java | 1 + .../ui/widgets/DAAdvancedPopupMenu.java | 163 ++++++ .../ui/widgets/DAAdvancedTabComposite.java | 113 +++++ .../ui/widgets/DAAdvancedViewComposite.java | 232 +++++++++ .../dynamicanalyzer/ui/widgets/FilterDialog.java | 553 +++++++++++++++++++++ .../dynamicanalyzer/ui/widgets/FilterInputRow.java | 210 ++++++++ .../ui/widgets/table/DAApiListTableComposite.java | 1 + .../ui/widgets/table/DATableCellRenderer.java | 0 .../ui/widgets/table/DATableComposite.java | 192 ++++++- .../ui/widgets/table/DATableEmptyCellRenderer.java | 0 .../ui/widgets/table/DATableHeaderRenderer.java | 2 +- .../ui/widgets/table/DATreeComposite.java | 8 +- .../widgets/table/DAWindowingTableComposite.java | 3 +- .../tizen/dynamicanalyzer/utils/AnalyzerUtil.java | 0 .../ui/file/data/FileApiDBTest.java | 2 +- os_stubs/macos/dynamic-analyzer.sh | 0 package/build.linux | 0 package/dynamic-analyzer-product.install.linux | 0 package/dynamic-analyzer-product.remove.linux | 0 test/setting/setting | 0 376 files changed, 4958 insertions(+), 1709 deletions(-) mode change 100755 => 100644 LICENSE.APLv2 mode change 100755 => 100644 LICENSE.BSD2c mode change 100755 => 100644 LICENSE.EPL mode change 100755 => 100644 LICENSE.LGPLv2.1 mode change 100755 => 100644 images/time_line_icon_UI_events.png mode change 100755 => 100644 images/time_line_icon_battery_usage.png mode change 100755 => 100644 images/time_line_icon_cpu_core.png mode change 100755 => 100644 images/time_line_icon_cpu_frequency.png mode change 100755 => 100644 images/time_line_icon_devices.png mode change 100755 => 100644 images/time_line_icon_electric_current.png mode change 100755 => 100644 images/time_line_icon_memory_allocation.png mode change 100755 => 100644 images/time_line_icon_memory_appusage.png mode change 100755 => 100644 images/time_line_icon_memory_process.png mode change 100755 => 100644 images/time_line_icon_memory_system.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/appearance/DesignConstants.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ColorResources.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/FontResources.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeBlack.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeWhite.java create mode 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DASearchTextBox.java create mode 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextCallbackEvent.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabButton.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabComposite.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DAViewComposite.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/dialog_edit_chart_minus.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/dialog_edit_chart_plus.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_Heap.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_UI_events.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_audio.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_battery_usage.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_bluetooth.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_brightness.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_camera.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu_core.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu_frequency.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_devices.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_electric_current.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_fd_usage.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_gps.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_allocation (2).png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_allocation.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_appusage.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_process.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_system.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_read_write.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_read_write_01.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_snapshot.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_sound.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_vibration.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_wifi.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/fail_api.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_UI_events.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_battery_usage.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_cpu_core.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_cpu_frequency.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_devices.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_electric_current.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_allocation.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_appusage.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_process.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_system.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_traffic.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_delete_filter_hover.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_delete_filter_normal.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_delete_filter_push.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_title_dropdown_hover.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_title_dropdown_normal.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_title_dropdown_push.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_hover.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_normal.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_push.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/feature_template_hierarchyviewer.png create mode 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/img_search_grey.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_pause_disable.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_pause_hover.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_pause_nor.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_pause_push.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_play_disable.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_play_hover.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_play_nor.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_play_push.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_stop_disable.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_stop_hover.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_stop_nor.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_stop_push.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.appearance/theme/white/img/toolbar_time_bg.png mode change 100755 => 100644 org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/model/Streamable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/ByteUtil.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/button/DACustomButton.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoard.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardItem.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardItemCell.java create mode 100644 org.tizen.dynamicanalyzer.workbench/Application.e4xmi mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/feature mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/Shortcut.vbs mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/cpio.exe mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/dd.exe mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/debuginfo.bat mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/gzip.exe mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/libiconv2.dll mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/libintl3.dll mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/md5sum.exe mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/od.exe mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/rpm2cpio.bat mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/dynamicanalyzer.product mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/common/path/PathManager.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/Application.java mode change 100755 => 100644 org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationWorkbenchWindowAdvisor.java mode change 100644 => 100755 org.tizen.dynamicanalyzer/ecs/gen.sh mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/AnalyzerManager.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/AnalyzerShellCommands.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/DALogExport.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/DAResult.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/BaseCommunicator.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/CommunicatorUtils.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DACommunicator.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DeviceManager.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/SubCommunicator.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/control/ApplistManager.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/listeners/AnalyzerPerspectiveListener.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/model/FilterProperty.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.properties mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.properties mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/UserErrorWarningLabels.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/UserErrorWarningLabels.properties mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/BinaryInfo.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/DeviceStatusInfo.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/Project.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/ApplicationInst30.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/FunctionInst30.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/LibraryInst30.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/Communicator30_UIHV.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConfig30_UIHV.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConstant30_UIHV.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/communicator/DataChannelThread.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/LogPackage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/LogParser.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/Logs.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/MessageParser.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogDataTimeComparator.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/common/TimeLineChartKeyListener.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/common/explorer/DAFileExplorerEmptyCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FilePage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/HierarchyPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/screenshot/ImageViewer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/InteractivePage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/ContextSwitchingChartView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/data/KernelDataMaker.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryAllocationTraceTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryChartView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryDetailsTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryMapView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryStatisticsTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/HeapMemoryChart.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/MemoryChart.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/MemoryChartBoard.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/ProcessMemoryChart.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/SystemMemoryChart.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/AllocateDBTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/FreeDBTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/MemoryDataManager.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/ProcessMemoryDBTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/SystemMemoryDBTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryAllocationTraceTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryDetailsTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryMapTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryStatisticsTable.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/GLPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/chart/GLChartView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPIListView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTableView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/BaseView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/ScreenshotTabComposite.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/range/RangePage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/SummaryPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedData.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingTableCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/ThreadChartView.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/TimelinePage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/chart/UserCustomChart.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/AddChartMenuComposite.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/TimelineConstants.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/logparser/CustomLogParser.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialogTableCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/SaveAsDialog.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/Toolbar.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/OpenTraceDialog.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/RepalyEditSaveDialog.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTableCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogOptionPage.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/UIPage.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedPopupMenu.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedTabComposite.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedViewComposite.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterDialog.java create mode 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterInputRow.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableEmptyCellRenderer.java mode change 100755 => 100644 org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/utils/AnalyzerUtil.java mode change 100644 => 100755 os_stubs/macos/dynamic-analyzer.sh mode change 100755 => 100644 package/build.linux mode change 100755 => 100644 package/dynamic-analyzer-product.install.linux mode change 100755 => 100644 package/dynamic-analyzer-product.remove.linux mode change 100755 => 100644 test/setting/setting diff --git a/LICENSE.APLv2 b/LICENSE.APLv2 old mode 100755 new mode 100644 diff --git a/LICENSE.BSD2c b/LICENSE.BSD2c old mode 100755 new mode 100644 diff --git a/LICENSE.EPL b/LICENSE.EPL old mode 100755 new mode 100644 diff --git a/LICENSE.LGPLv2.1 b/LICENSE.LGPLv2.1 old mode 100755 new mode 100644 diff --git a/images/time_line_icon_UI_events.png b/images/time_line_icon_UI_events.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_battery_usage.png b/images/time_line_icon_battery_usage.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_cpu_core.png b/images/time_line_icon_cpu_core.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_cpu_frequency.png b/images/time_line_icon_cpu_frequency.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_devices.png b/images/time_line_icon_devices.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_electric_current.png b/images/time_line_icon_electric_current.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_memory_allocation.png b/images/time_line_icon_memory_allocation.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_memory_appusage.png b/images/time_line_icon_memory_appusage.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_memory_process.png b/images/time_line_icon_memory_process.png old mode 100755 new mode 100644 diff --git a/images/time_line_icon_memory_system.png b/images/time_line_icon_memory_system.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/.classpath b/org.tizen.dynamicanalyzer.appearance/.classpath index ad32c83..098194c 100644 --- a/org.tizen.dynamicanalyzer.appearance/.classpath +++ b/org.tizen.dynamicanalyzer.appearance/.classpath @@ -1,6 +1,6 @@ - + diff --git a/org.tizen.dynamicanalyzer.appearance/.settings/org.eclipse.jdt.core.prefs b/org.tizen.dynamicanalyzer.appearance/.settings/org.eclipse.jdt.core.prefs index c537b63..f42de36 100644 --- a/org.tizen.dynamicanalyzer.appearance/.settings/org.eclipse.jdt.core.prefs +++ b/org.tizen.dynamicanalyzer.appearance/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,7 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.compliance=1.7 org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.compiler.source=1.7 diff --git a/org.tizen.dynamicanalyzer.appearance/META-INF/MANIFEST.MF b/org.tizen.dynamicanalyzer.appearance/META-INF/MANIFEST.MF index 2c61e2d..47797fb 100644 --- a/org.tizen.dynamicanalyzer.appearance/META-INF/MANIFEST.MF +++ b/org.tizen.dynamicanalyzer.appearance/META-INF/MANIFEST.MF @@ -9,7 +9,7 @@ Require-Bundle: org.eclipse.ui, org.tizen.dynamicanalyzer.common;bundle-version="1.0.0", org.tizen.dynamicanalyzer.widgets;bundle-version="1.0.0" Bundle-ActivationPolicy: lazy -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Export-Package: org.tizen.dynamicanalyzer.appearance, org.tizen.dynamicanalyzer.nl, org.tizen.dynamicanalyzer.resources, diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/appearance/DesignConstants.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/appearance/DesignConstants.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ColorResources.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ColorResources.java old mode 100755 new mode 100644 index e212356..5520677 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ColorResources.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ColorResources.java @@ -609,6 +609,15 @@ public class ColorResources { /** progress dialog percentage text ***/ public static final Color PROGRESS_PERCENTAGE_FONT_COLOR = getColor("progress_percentage_font_color", new RGB(23, 51, 56)); //$NON-NLS-1$ + /** text box **/ + public static final Color TEXT_BOX_MESSAGE = getColor("text_box_message", new RGB(160, 160, 160)); + + /** filter dialog **/ + public static final Color FILTER_DIALOG_DEFAULT_BACKGROUND_COLOR = + getColor("filter_dialog_default_background_color"); //$NON-NLS-1$ + public static final Color FILTER_DIALOG_WHITE_BACKGROUND_COLOR = + getColor("filter_dialog_white_background_color"); //$NON-NLS-1$ + // public static void initColors() { // WINDOW_BG_COLOR = getColor("window_bg_color"); //$NON-NLS-1$ // @@ -958,4 +967,4 @@ public class ColorResources { private static Color getColor(String colorName) { return DAThemeWhite.getInstance().getColor(colorName); } -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/FontResources.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/FontResources.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ImageResources.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ImageResources.java index a925114..1066b51 100644 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ImageResources.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/resources/ImageResources.java @@ -446,6 +446,7 @@ public class ImageResources { public static final Image TEMPLATE_NETWORK_ANALYSIS = getPngImage("feature_template_network"); //$NON-NLS-1$ public static final Image TEMPLATE_OPEN_GL_ANALYSIS = getPngImage("feature_template_opengl"); //$NON-NLS-1$ public static final Image TEMPLATE_ENERGY = getPngImage("feature_template_energy"); //$NON-NLS-1$ + public static final Image TEMPLATE_UI_HIERARCHY_ANALYSIS = getPngImage("feature_template_hierarchyviewer"); //$NON-NLS-1$ public static final Image TEMPLATE_CUSTOM = getPngImage("feature_template_custom"); //$NON-NLS-1$ public static final Image OVERHEAD_BAR = getPngImage("overhead_bar"); //$NON-NLS-1$ @@ -491,6 +492,17 @@ public class ImageResources { /* text box*/ public static final Image TEXT_BOX_WARNING = getPngImage("icon_error_warning"); //$NON-NLS-1$ public static final Image TEXT_BOX_OK = getPngImage("icon_error_ok"); //$NON-NLS-1$ + public static final Image SEARCH_IMAGE = getPngImage("img_search_grey"); //$NON-NLS-1$ + + /** advanced view button **/ + public static final Image ADVANCED_MENU_BUTTON_NORMAL = getPngImage("btn_title_dropdown_normal"); //$NON-NLS-1$ + + /** table filtering **/ + public static final Image COLUMN_FILTER_NORMAL = getPngImage("column_filter_normal"); //$NON-NLS-1$ + + public static final Image FILTER_DIALOG_DELETE_FILTER_NORMAL = getPngImage("btn_delete_filter_normal"); //$NON-NLS-1$ + public static final Image FILTER_DIALOG_DELETE_FILTER_HOVER = getPngImage("btn_delete_filter_hover"); //$NON-NLS-1$ + public static final Image FILTER_DIALOG_DELETE_FILTER_PUSH = getPngImage("btn_delete_filter_push"); //$NON-NLS-1$ private static Image getImage(String pluginId, String folderName, String imageName, String extension) { @@ -525,4 +537,4 @@ public class ImageResources { private static Image getGifImage(String imageName) { return getImage(imageName, CommonConstants.EXTENSION_GIF_IMAGE); } -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeBlack.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeBlack.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeWhite.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeWhite.java old mode 100755 new mode 100644 index a7b0ae1..f1e5166 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeWhite.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/theme/DAThemeWhite.java @@ -602,6 +602,10 @@ public class DAThemeWhite extends DATheme { setColor("feature_overhead_ranking_normal", new RGB(50, 50, 50)); //$NON-NLS-1$ setColor("feature_overhead_ranking_middle", new RGB(208, 79, 15)); //$NON-NLS-1$ setColor("feature_overhead_ranking_high", new RGB(255, 0, 0)); //$NON-NLS-1$ + + /** filter dialog **/ + setColor("filter_dialog_default_background_color", new RGB(232, 234, 235)); //$NON-NLS-1$ + setColor("filter_dialog_white_background_color", new RGB(255, 255, 255)); //$NON-NLS-1$ } public Color getColor(String colorName, RGB rgb) { diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAAbstractText.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAAbstractText.java index 1446fc9..4e0609c 100644 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAAbstractText.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAAbstractText.java @@ -5,6 +5,7 @@ * * Contact: * Hyeran Kim + * Woojin Jung * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -166,4 +167,4 @@ public abstract class DAAbstractText { public void setFont(Font font) { this.text.setFont(font); } -} +} \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DASearchTextBox.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DASearchTextBox.java new file mode 100644 index 0000000..2c4e142 --- /dev/null +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DASearchTextBox.java @@ -0,0 +1,140 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Hyeran Kim + * Woojin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.widgets.da.base; + +import org.eclipse.swt.SWT; +import org.eclipse.swt.events.FocusEvent; +import org.eclipse.swt.events.FocusListener; +import org.eclipse.swt.events.KeyEvent; +import org.eclipse.swt.events.KeyListener; +import org.eclipse.swt.events.PaintEvent; +import org.eclipse.swt.events.PaintListener; +import org.eclipse.swt.events.SelectionAdapter; +import org.eclipse.swt.events.SelectionEvent; +import org.eclipse.swt.graphics.Image; +import org.eclipse.swt.graphics.Rectangle; +import org.eclipse.swt.layout.FormAttachment; +import org.eclipse.swt.layout.FormData; +import org.eclipse.swt.layout.FormLayout; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Text; +import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.resources.FontResources; +import org.tizen.dynamicanalyzer.resources.ImageResources; +import org.tizen.dynamicanalyzer.util.Logger; + +public class DASearchTextBox extends DAAbstractText { + private Composite composite = null; + private Image searchImage = ImageResources.SEARCH_IMAGE; + DATextCallbackEvent searcher = null; + + public DASearchTextBox(Composite parent, int style) { + composite = new Composite(parent, SWT.DOUBLE_BUFFERED); + composite.setLayout(new FormLayout()); + composite.setBackground(ColorResources.WHITE); + + text = new Text(composite, style); + text.setBackground(ColorResources.WHITE); + text.setForeground(ColorResources.TEXT_BOX_MESSAGE); + text.setFont(FontResources.getDADefaultFont()); + text.setMessage("Search"); + + text.addSelectionListener(new SelectionAdapter() { + @Override + public void widgetDefaultSelected(SelectionEvent e) { + // It's called when enter key pressed + if (e.detail != SWT.CANCEL) { + if(searcher != null) { + searcher.searchforText(text.getText()); + } else { + Logger.debug("searcher is null, register CallbackEvent!!"); + } + } + } + }); + + + composite.addPaintListener(new PaintListener() { + @Override + public void paintControl(PaintEvent e) { + Composite comp = (Composite) e.widget; + Rectangle rect = comp.getClientArea(); + e.gc.setForeground(boaderColor); + e.gc.drawRectangle(rect.x, rect.y, rect.width-1, rect.height-1); + // draw a image in text box + e.gc.drawImage(searchImage, 4, 2); + } + }); + + text.addListener(SWT.MouseEnter, textMouseListener); + text.addListener(SWT.MouseExit, textMouseListener); + text.addListener(SWT.MouseDown, textMouseListener); + text.addListener(SWT.MouseUp, textMouseListener); + text.addListener(SWT.MouseHover, textMouseListener); + + text.addFocusListener(new FocusListener() { + + @Override + public void focusLost(FocusEvent e) { + boaderColor = ColorResources.TEXT_NORMAL_COLOR; + } + + @Override + public void focusGained(FocusEvent e) { + + } + }); + } + + // layout text field in composite + public void setLayoutData(FormData data) { + composite.setLayoutData(data); + + // text + data = new FormData(); + data.top = new FormAttachment(0, 1); + data.bottom = new FormAttachment(100, -1); + data.left = new FormAttachment(0, 26); + data.right = new FormAttachment(100, -1); + text.setLayoutData(data); + + composite.layout(); + } + + @Override + void redraw() { + composite.redraw(); + } + + public void setSearchImage(Image image) { + this.searchImage = image; + } + + public void registerCallbackEvent(DATextCallbackEvent event) { + this.searcher = event; + } +} \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextBox.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextBox.java index 8eb5139..4f8011b 100644 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextBox.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextBox.java @@ -5,6 +5,7 @@ * * Contact: * Hyeran Kim + * Woojin Jung * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -66,7 +67,6 @@ public class DATextBox extends DAAbstractText{ @Override public void focusGained(FocusEvent e) { - // TODO Auto-generated method stub } }); @@ -76,4 +76,4 @@ public class DATextBox extends DAAbstractText{ void redraw() { text.redraw(); } -} +} \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextCallbackEvent.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextCallbackEvent.java new file mode 100644 index 0000000..88f3b58 --- /dev/null +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DATextCallbackEvent.java @@ -0,0 +1,40 @@ + +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Hyeran Kim + * Woojin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.widgets.da.base; + +/** + * Callback Event for text input box + */ +public interface DATextCallbackEvent { + + // validate text in text field + public boolean checkValidation(String text); + + // search for text + public void searchforText(String text); +} \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAValidTextBox.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAValidTextBox.java index 497492d..2dca49e 100644 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAValidTextBox.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/base/DAValidTextBox.java @@ -5,6 +5,7 @@ * * Contact: * Hyeran Kim + * Woojin Jung * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -43,16 +44,15 @@ import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Text; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.resources.ImageResources; +import org.tizen.dynamicanalyzer.util.Logger; public class DAValidTextBox extends DAAbstractText{ private Composite composite = null; private Image iconImage = ImageResources.TEXT_BOX_OK; //16x16 private int imageArea = 20; - DAValidationChecker validationChecker = null; + DATextCallbackEvent validationChecker = null; public DAValidTextBox(Composite parent, int style) { - this.validationChecker = (DAValidationChecker) parent; - composite = new Composite(parent, SWT.DOUBLE_BUFFERED); composite.setLayout(new FormLayout()); @@ -98,12 +98,16 @@ public class DAValidTextBox extends DAAbstractText{ @Override public void keyReleased(KeyEvent e) { // check validation and change icon image - if(validationChecker.validate()){ - iconImage = ImageResources.TEXT_BOX_OK; + if(validationChecker != null) { + if(validationChecker.checkValidation(text.getText())){ + iconImage = ImageResources.TEXT_BOX_OK; + }else{ + iconImage = ImageResources.TEXT_BOX_WARNING; + } + composite.redraw(); }else{ - iconImage = ImageResources.TEXT_BOX_WARNING; + Logger.debug("validationChecker is null, register CallbackEvent!!"); } - composite.redraw(); } @Override @@ -147,4 +151,7 @@ public class DAValidTextBox extends DAAbstractText{ composite.redraw(); } -} + public void registerCallbackEvent(DATextCallbackEvent event) { + this.validationChecker = event; + } +} \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabButton.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabButton.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabComposite.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabComposite.java old mode 100755 new mode 100644 index 6ee1f47..fb3fa35 --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabComposite.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DATabComposite.java @@ -65,8 +65,8 @@ public class DATabComposite extends DABaseComposite { private List buttons = null; private List children = null; - private Composite tabComposite = null; - private Composite contentsComposite = null; + protected Composite tabComposite = null; + protected Composite contentsComposite = null; private StackLayout contentsStackLayout = null; private Control lasttab = null; diff --git a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DAViewComposite.java b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DAViewComposite.java old mode 100755 new mode 100644 index 3dccfe0..f39591c --- a/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DAViewComposite.java +++ b/org.tizen.dynamicanalyzer.appearance/src/org/tizen/dynamicanalyzer/widgets/da/view/DAViewComposite.java @@ -56,8 +56,8 @@ public abstract class DAViewComposite extends DABaseComposite { private static final int OFFSET = 5; // ui components - private Canvas titleBar = null; - private Composite contentArea = null; + protected Canvas titleBar = null; + protected Composite contentArea = null; private Color titleFontColor = ColorResources.VIEW_TITLE_FONT_COLOR; private boolean isMaximized = false; diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/dialog_edit_chart_minus.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/dialog_edit_chart_minus.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/dialog_edit_chart_plus.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/dialog_edit_chart_plus.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_Heap.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_Heap.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_UI_events.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_UI_events.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_audio.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_audio.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_battery_usage.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_battery_usage.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_bluetooth.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_bluetooth.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_brightness.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_brightness.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_camera.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_camera.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu_core.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu_core.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu_frequency.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_cpu_frequency.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_devices.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_devices.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_electric_current.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_electric_current.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_fd_usage.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_fd_usage.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_gps.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_gps.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_allocation (2).png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_allocation (2).png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_allocation.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_allocation.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_appusage.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_appusage.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_process.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_process.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_system.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_memory_system.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_read_write.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_read_write.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_read_write_01.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_read_write_01.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_snapshot.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_snapshot.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_sound.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_sound.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_vibration.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_vibration.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_wifi.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/edit_chart_icon_wifi.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/fail_api.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/fail_api.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_UI_events.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_UI_events.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_battery_usage.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_battery_usage.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_cpu_core.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_cpu_core.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_cpu_frequency.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_cpu_frequency.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_devices.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_devices.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_electric_current.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_electric_current.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_allocation.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_allocation.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_appusage.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_appusage.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_process.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_process.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_system.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_memory_system.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_traffic.png b/org.tizen.dynamicanalyzer.appearance/theme/black/img/time_line_icon_traffic.png old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_delete_filter_hover.png b/org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_delete_filter_hover.png new file mode 100644 index 0000000000000000000000000000000000000000..3d06e7db3c9aa3571765900d57c1fbf36800e358 GIT binary patch literal 3209 zcmV;440iL0P)KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;Kp2HUQ-ZMJ=3XJQv;x5ci*?vuTfeY$;({XGW_huIFR9a(?@3)XSs8O^N5RyOM=TTmp(3=8^+zpz2r)C z^>JO{deZfso3oq3?Wo(Y?l$ge?uXo;%ru`Vo>?<<(8I_>;8Eq#KMS9gFl*neeosSB zfoHYnBQIkwkyowPu(zdms`p{<7e4kra-ZWq<2*OsGTvEV%s0Td$hXT+!*8Bnh2KMe zBmZRodjHV?r+_5^X9J0WL4jKW`}lf%A-|44I@@LTvf1rHjG(ze6+w@Jt%Bvjts!X0 z?2xS?_ve_-kiKB_KiJlZ$9G`c^=E@oNG)mWWaNo-3TIW8)$Hg0Ub-~8?KhvJ>$ z3*&nim@mj(aCxE5!t{lw7O5^0EIO7zOo&c6l<+|iDySBWCGrz@C5{St!X3hAA}`T4 z(TLbXTq+(;@<=L8dXnssyft|w#WSTW<++3>sgS%(4NTpeI-VAqb|7ssJvzNHgOZVu zaYCvgO_R1~>SyL=cFU|~g|hy|Zi}}s9+d~lYqOB71z9Z$wnC=pR9Yz4DhIM>Wmjgu z&56o6maCpC&F##y%G;1PobR9i?GnNg;gYtchD%p19a!eQtZF&3JaKv33gZ<8D~47E ztUS1iwkmDaPpj=$m#%)jCVEY4fnLGNg2A-`YwHVD3gv};>)hAvT~AmqS>Lr``i7kw zJ{5_It`yrBmlc25DBO7E8;5VoznR>Ww5hAaxn$2~(q`%A-YuS64wkBy=9dm`4cXeX z4c}I@?e+FW+b@^RDBHV(wnMq2zdX3SWv9u`%{xC-q*U}&`cyXV(%rRT*Z6MH?i+i& z_B8C(+grT%{XWUQ+f@NoP1R=AW&26{v-dx)iK^-Nmiuj8txj!m?Z*Ss1N{dh4z}01 z)YTo*JycSU)+_5r4#yw9{+;i4Ee$peRgIj+;v;ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0005BNkl(gZBTZ8jKn&ngz_&O%#1fQ6NUSVb$r4hOx0YH-|_h7)3p$xVpWiVcX}xktL-geA`~ZFg8qG9~lmi)HF<8 zr(hVHz#f3`YrdPGo&E69Lb=RBxg7f*VE&D@b6}cl0$5+kq(S+W=#OqdaL#P;!kCqK73aHo>IY7SA$8m3Wl+7>iU<|T{;d8+di?R zJP4XxY1sB}={WQ~Z)9*!sQ`WsQ~KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;Kp2HUQ-ZMJ=3XJQv;x5ci*?vuTfeY$;({XGW_huIFR9a(?@3)XSs8O^N5RyOM=TTmp(3=8^+zpz2r)C z^>JO{deZfso3oq3?Wo(Y?l$ge?uXo;%ru`Vo>?<<(8I_>;8Eq#KMS9gFl*neeosSB zfoHYnBQIkwkyowPu(zdms`p{<7e4kra-ZWq<2*OsGTvEV%s0Td$hXT+!*8Bnh2KMe zBmZRodjHV?r+_5^X9J0WL4jKW`}lf%A-|44I@@LTvf1rHjG(ze6+w@Jt%Bvjts!X0 z?2xS?_ve_-kiKB_KiJlZ$9G`c^=E@oNG)mWWaNo-3TIW8)$Hg0Ub-~8?KhvJ>$ z3*&nim@mj(aCxE5!t{lw7O5^0EIO7zOo&c6l<+|iDySBWCGrz@C5{St!X3hAA}`T4 z(TLbXTq+(;@<=L8dXnssyft|w#WSTW<++3>sgS%(4NTpeI-VAqb|7ssJvzNHgOZVu zaYCvgO_R1~>SyL=cFU|~g|hy|Zi}}s9+d~lYqOB71z9Z$wnC=pR9Yz4DhIM>Wmjgu z&56o6maCpC&F##y%G;1PobR9i?GnNg;gYtchD%p19a!eQtZF&3JaKv33gZ<8D~47E ztUS1iwkmDaPpj=$m#%)jCVEY4fnLGNg2A-`YwHVD3gv};>)hAvT~AmqS>Lr``i7kw zJ{5_It`yrBmlc25DBO7E8;5VoznR>Ww5hAaxn$2~(q`%A-YuS64wkBy=9dm`4cXeX z4c}I@?e+FW+b@^RDBHV(wnMq2zdX3SWv9u`%{xC-q*U}&`cyXV(%rRT*Z6MH?i+i& z_B8C(+grT%{XWUQ+f@NoP1R=AW&26{v-dx)iK^-Nmiuj8txj!m?Z*Ss1N{dh4z}01 z)YTo*JycSU)+_5r4#yw9{+;i4Ee$peRgIj+;v;ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0003DNkl+wHH3)x*%&#n(qrlr5VYkYb jU&C%WWPryeKLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;Kp2HUQ-ZMJ=3XJQv;x5ci*?vuTfeY$;({XGW_huIFR9a(?@3)XSs8O^N5RyOM=TTmp(3=8^+zpz2r)C z^>JO{deZfso3oq3?Wo(Y?l$ge?uXo;%ru`Vo>?<<(8I_>;8Eq#KMS9gFl*neeosSB zfoHYnBQIkwkyowPu(zdms`p{<7e4kra-ZWq<2*OsGTvEV%s0Td$hXT+!*8Bnh2KMe zBmZRodjHV?r+_5^X9J0WL4jKW`}lf%A-|44I@@LTvf1rHjG(ze6+w@Jt%Bvjts!X0 z?2xS?_ve_-kiKB_KiJlZ$9G`c^=E@oNG)mWWaNo-3TIW8)$Hg0Ub-~8?KhvJ>$ z3*&nim@mj(aCxE5!t{lw7O5^0EIO7zOo&c6l<+|iDySBWCGrz@C5{St!X3hAA}`T4 z(TLbXTq+(;@<=L8dXnssyft|w#WSTW<++3>sgS%(4NTpeI-VAqb|7ssJvzNHgOZVu zaYCvgO_R1~>SyL=cFU|~g|hy|Zi}}s9+d~lYqOB71z9Z$wnC=pR9Yz4DhIM>Wmjgu z&56o6maCpC&F##y%G;1PobR9i?GnNg;gYtchD%p19a!eQtZF&3JaKv33gZ<8D~47E ztUS1iwkmDaPpj=$m#%)jCVEY4fnLGNg2A-`YwHVD3gv};>)hAvT~AmqS>Lr``i7kw zJ{5_It`yrBmlc25DBO7E8;5VoznR>Ww5hAaxn$2~(q`%A-YuS64wkBy=9dm`4cXeX z4c}I@?e+FW+b@^RDBHV(wnMq2zdX3SWv9u`%{xC-q*U}&`cyXV(%rRT*Z6MH?i+i& z_B8C(+grT%{XWUQ+f@NoP1R=AW&26{v-dx)iK^-Nmiuj8txj!m?Z*Ss1N{dh4z}01 z)YTo*JycSU)+_5r4#yw9{+;i4Ee$peRgIj+;v;ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0004b$i zfs|L-0vo`IC&d1i<6!bKDXqDj%@{{fA2RePl)~I5^w<9Flagso)BMv4uF|> z{^Mi4{^TWpIK&?gEAInrKC-?awA;HTu-A6ox>e$L3Vdo^^e1iCb%8w-@ZZ~Z;o;HF zPT{Mw-||YBz6rEeO9~W$%HRMAv$ag7m1F{wTcs-dUp0q>IWd9JO-X^g=lM*ElrTpo zFpyz5yHC2ZN)FHYue46PdXRQ<;0e)fI?k*3ei6rvqv$x0@*oYlH;$s;7jevD39!;S zh4+CTfaR~R15AOx*YmkJkK^rzZCmdw3#-DgTLAx+;@{mJf2Py$dOkk|j`G9q&Bpb^ Y0BT^e|Gu(zZ~y=R07*qoM6N<$g6v4|kpKVy literal 0 HcmV?d00001 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_title_dropdown_hover.png b/org.tizen.dynamicanalyzer.appearance/theme/white/img/btn_title_dropdown_hover.png new file mode 100644 index 0000000000000000000000000000000000000000..71939b4b30a734700850ae30a9fd9257afb167c2 GIT binary patch literal 2874 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 R>?HsI002ovPDHLkV1fy;hHd}= literal 0 HcmV?d00001 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_hover.png b/org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_hover.png new file mode 100644 index 0000000000000000000000000000000000000000..73638666c1d217946f240b96114a8e46c642cf36 GIT binary patch literal 2879 zcmV-F3&8Y=P)KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;Kp2HUQ-ZMJ=3XJQv;x5ci*?vuTfeY$;({XGW_huIFR9a(?@3)XSs8O^N5RyOM=TTmp(3=8^+zpz2r)C z^>JO{deZfso3oq3?Wo(Y?l$ge?uXo;%ru`Vo>?<<(8I_>;8Eq#KMS9gFl*neeosSB zfoHYnBQIkwkyowPu(zdms`p{<7e4kra-ZWq<2*OsGTvEV%s0Td$hXT+!*8Bnh2KMe zBmZRodjHV?r+_5^X9J0WL4jKW`}lf%A-|44I@@LTvf1rHjG(ze6+w@Jt%Bvjts!X0 z?2xS?_ve_-kiKB_KiJlZ$9G`c^=E@oNG)mWWaNo-3TIW8)$Hg0Ub-~8?KhvJ>$ z3*&nim@mj(aCxE5!t{lw7O5^0EIO7zOo&c6l<+|iDySBWCGrz@C5{St!X3hAA}`T4 z(TLbXTq+(;@<=L8dXnssyft|w#WSTW<++3>sgS%(4NTpeI-VAqb|7ssJvzNHgOZVu zaYCvgO_R1~>SyL=cFU|~g|hy|Zi}}s9+d~lYqOB71z9Z$wnC=pR9Yz4DhIM>Wmjgu z&56o6maCpC&F##y%G;1PobR9i?GnNg;gYtchD%p19a!eQtZF&3JaKv33gZ<8D~47E ztUS1iwkmDaPpj=$m#%)jCVEY4fnLGNg2A-`YwHVD3gv};>)hAvT~AmqS>Lr``i7kw zJ{5_It`yrBmlc25DBO7E8;5VoznR>Ww5hAaxn$2~(q`%A-YuS64wkBy=9dm`4cXeX z4c}I@?e+FW+b@^RDBHV(wnMq2zdX3SWv9u`%{xC-q*U}&`cyXV(%rRT*Z6MH?i+i& z_B8C(+grT%{XWUQ+f@NoP1R=AW&26{v-dx)iK^-Nmiuj8txj!m?Z*Ss1N{dh4z}01 z)YTo*JycSU)+_5r4#yw9{+;i4Ee$peRgIj+;v;ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0001LNklKLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;Kp2HUQ-ZMJ=3XJQv;x5ci*?vuTfeY$;({XGW_huIFR9a(?@3)XSs8O^N5RyOM=TTmp(3=8^+zpz2r)C z^>JO{deZfso3oq3?Wo(Y?l$ge?uXo;%ru`Vo>?<<(8I_>;8Eq#KMS9gFl*neeosSB zfoHYnBQIkwkyowPu(zdms`p{<7e4kra-ZWq<2*OsGTvEV%s0Td$hXT+!*8Bnh2KMe zBmZRodjHV?r+_5^X9J0WL4jKW`}lf%A-|44I@@LTvf1rHjG(ze6+w@Jt%Bvjts!X0 z?2xS?_ve_-kiKB_KiJlZ$9G`c^=E@oNG)mWWaNo-3TIW8)$Hg0Ub-~8?KhvJ>$ z3*&nim@mj(aCxE5!t{lw7O5^0EIO7zOo&c6l<+|iDySBWCGrz@C5{St!X3hAA}`T4 z(TLbXTq+(;@<=L8dXnssyft|w#WSTW<++3>sgS%(4NTpeI-VAqb|7ssJvzNHgOZVu zaYCvgO_R1~>SyL=cFU|~g|hy|Zi}}s9+d~lYqOB71z9Z$wnC=pR9Yz4DhIM>Wmjgu z&56o6maCpC&F##y%G;1PobR9i?GnNg;gYtchD%p19a!eQtZF&3JaKv33gZ<8D~47E ztUS1iwkmDaPpj=$m#%)jCVEY4fnLGNg2A-`YwHVD3gv};>)hAvT~AmqS>Lr``i7kw zJ{5_It`yrBmlc25DBO7E8;5VoznR>Ww5hAaxn$2~(q`%A-YuS64wkBy=9dm`4cXeX z4c}I@?e+FW+b@^RDBHV(wnMq2zdX3SWv9u`%{xC-q*U}&`cyXV(%rRT*Z6MH?i+i& z_B8C(+grT%{XWUQ+f@NoP1R=AW&26{v-dx)iK^-Nmiuj8txj!m?Z*Ss1N{dh4z}01 z)YTo*JycSU)+_5r4#yw9{+;i4Ee$peRgIj+;v;ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0001SNklggXfxG#|V4pC}vfIgbU&G+g>n k;)#jK;AbRN16&he0K=0T04&^;#sB~S07*qoM6N<$g4A|b!~g&Q literal 0 HcmV?d00001 diff --git a/org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_push.png b/org.tizen.dynamicanalyzer.appearance/theme/white/img/column_filter_push.png new file mode 100644 index 0000000000000000000000000000000000000000..afe437737694e6a508d933ba0d4d6645efec8241 GIT binary patch literal 2872 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 - + diff --git a/org.tizen.dynamicanalyzer.common/.settings/org.eclipse.jdt.core.prefs b/org.tizen.dynamicanalyzer.common/.settings/org.eclipse.jdt.core.prefs index c537b63..f42de36 100644 --- a/org.tizen.dynamicanalyzer.common/.settings/org.eclipse.jdt.core.prefs +++ b/org.tizen.dynamicanalyzer.common/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,7 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.compliance=1.7 org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.compiler.source=1.7 diff --git a/org.tizen.dynamicanalyzer.common/META-INF/MANIFEST.MF b/org.tizen.dynamicanalyzer.common/META-INF/MANIFEST.MF index 0275f35..84b3438 100644 --- a/org.tizen.dynamicanalyzer.common/META-INF/MANIFEST.MF +++ b/org.tizen.dynamicanalyzer.common/META-INF/MANIFEST.MF @@ -7,7 +7,7 @@ Bundle-Activator: org.tizen.dynamicanalyzer.common.Activator Require-Bundle: org.eclipse.ui, org.eclipse.core.runtime Bundle-ActivationPolicy: lazy -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Export-Package: org.tizen.dynamicanalyzer.annotation, org.tizen.dynamicanalyzer.callback, org.tizen.dynamicanalyzer.constant, diff --git a/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/model/Streamable.java b/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/model/Streamable.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/ByteUtil.java b/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/ByteUtil.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/UnsignedInt.java b/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/UnsignedInt.java index 0883cee..398366a 100644 --- a/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/UnsignedInt.java +++ b/org.tizen.dynamicanalyzer.common/src/org/tizen/dynamicanalyzer/util/UnsignedInt.java @@ -48,7 +48,7 @@ public class UnsignedInt { this.value = value; } } - + public UnsignedInt clone() { return new UnsignedInt(this.value); } @@ -73,6 +73,11 @@ public class UnsignedInt { } } + @Override + public String toString() { + return Long.toString(value); + } + public long getValue() { return value; } diff --git a/org.tizen.dynamicanalyzer.splash/plugin.properties b/org.tizen.dynamicanalyzer.splash/plugin.properties index f74d8aa..dead015 100644 --- a/org.tizen.dynamicanalyzer.splash/plugin.properties +++ b/org.tizen.dynamicanalyzer.splash/plugin.properties @@ -1,4 +1,4 @@ #Plugin name -pluginName=Tizen Dynamic Analyzer splash +pluginName=Dynamic Analyzer splash #Provider name providerName=Samsung Electronics diff --git a/org.tizen.dynamicanalyzer.widgets/.classpath b/org.tizen.dynamicanalyzer.widgets/.classpath index 70f9e81..1baaec6 100644 --- a/org.tizen.dynamicanalyzer.widgets/.classpath +++ b/org.tizen.dynamicanalyzer.widgets/.classpath @@ -1,6 +1,6 @@ - + diff --git a/org.tizen.dynamicanalyzer.widgets/.settings/org.eclipse.jdt.core.prefs b/org.tizen.dynamicanalyzer.widgets/.settings/org.eclipse.jdt.core.prefs index cf90579..f42de36 100644 --- a/org.tizen.dynamicanalyzer.widgets/.settings/org.eclipse.jdt.core.prefs +++ b/org.tizen.dynamicanalyzer.widgets/.settings/org.eclipse.jdt.core.prefs @@ -1,8 +1,7 @@ -#Thu Jul 05 13:02:20 KST 2012 eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.compliance=1.7 org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.compiler.source=1.7 diff --git a/org.tizen.dynamicanalyzer.widgets/META-INF/MANIFEST.MF b/org.tizen.dynamicanalyzer.widgets/META-INF/MANIFEST.MF index 6befc6c..31413c2 100644 --- a/org.tizen.dynamicanalyzer.widgets/META-INF/MANIFEST.MF +++ b/org.tizen.dynamicanalyzer.widgets/META-INF/MANIFEST.MF @@ -8,7 +8,7 @@ Require-Bundle: org.eclipse.ui, org.eclipse.core.runtime, org.tizen.dynamicanalyzer.common;bundle-version="1.0.0" Bundle-ActivationPolicy: lazy -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Export-Package: org.tizen.dynamicanalyzer.widgets, org.tizen.dynamicanalyzer.widgets.animation, org.tizen.dynamicanalyzer.widgets.button, diff --git a/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/button/DACustomButton.java b/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/button/DACustomButton.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoard.java b/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoard.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardHeightChangeableItem.java b/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardHeightChangeableItem.java index ffddcca..ee24555 100644 --- a/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardHeightChangeableItem.java +++ b/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardHeightChangeableItem.java @@ -30,7 +30,7 @@ package org.tizen.dynamicanalyzer.widgets.chartBoard; import org.eclipse.swt.layout.FormData; public class DAChartBoardHeightChangeableItem extends DAChartBoardItem { - private double originalHeightRatio = -1; + private double originalHeightRatio = 1; public DAChartBoardHeightChangeableItem(DAChartBoardItem parent, String itemName) { diff --git a/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardItem.java b/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardItem.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardItemCell.java b/org.tizen.dynamicanalyzer.widgets/src/org/tizen/dynamicanalyzer/widgets/chartBoard/DAChartBoardItemCell.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench.feature/feature.properties b/org.tizen.dynamicanalyzer.workbench.feature/feature.properties index 533294b..9809fdb 100644 --- a/org.tizen.dynamicanalyzer.workbench.feature/feature.properties +++ b/org.tizen.dynamicanalyzer.workbench.feature/feature.properties @@ -15,7 +15,7 @@ # This file should be translated. #Plugin name -featureName=Tizen Dynamic Analyzer +featureName=Dynamic Analyzer #Provider name providerName=Samsung Electronics diff --git a/org.tizen.dynamicanalyzer.workbench.feature/feature.xml b/org.tizen.dynamicanalyzer.workbench.feature/feature.xml index 28c5e9d..3a5001d 100644 --- a/org.tizen.dynamicanalyzer.workbench.feature/feature.xml +++ b/org.tizen.dynamicanalyzer.workbench.feature/feature.xml @@ -173,13 +173,6 @@ unpack="false"/> - - - - - - - - - - + + + + + + + diff --git a/org.tizen.dynamicanalyzer.workbench/.settings/org.eclipse.jdt.core.prefs b/org.tizen.dynamicanalyzer.workbench/.settings/org.eclipse.jdt.core.prefs index 7ee71a7..f42de36 100644 --- a/org.tizen.dynamicanalyzer.workbench/.settings/org.eclipse.jdt.core.prefs +++ b/org.tizen.dynamicanalyzer.workbench/.settings/org.eclipse.jdt.core.prefs @@ -1,8 +1,7 @@ -#Sat Jan 29 17:22:41 KST 2011 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.compliance=1.7 +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.7 diff --git a/org.tizen.dynamicanalyzer.workbench/Application.e4xmi b/org.tizen.dynamicanalyzer.workbench/Application.e4xmi new file mode 100644 index 0000000..d11a9be --- /dev/null +++ b/org.tizen.dynamicanalyzer.workbench/Application.e4xmi @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/org.tizen.dynamicanalyzer.workbench/META-INF/MANIFEST.MF b/org.tizen.dynamicanalyzer.workbench/META-INF/MANIFEST.MF index 8872df9..792836c 100644 --- a/org.tizen.dynamicanalyzer.workbench/META-INF/MANIFEST.MF +++ b/org.tizen.dynamicanalyzer.workbench/META-INF/MANIFEST.MF @@ -9,8 +9,7 @@ Require-Bundle: org.eclipse.core.runtime, org.eclipse.ui, org.tizen.dynamicanalyzer.common;bundle-version="1.0.0", org.tizen.dynamicanalyzer.appearance;bundle-version="1.0.0" - -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Export-Package: org.tizen.dynamicanalyzer.common.path, org.tizen.dynamicanalyzer.util, org.tizen.dynamicanalyzer.workbench; diff --git a/org.tizen.dynamicanalyzer.workbench/build.properties b/org.tizen.dynamicanalyzer.workbench/build.properties index 0c042f1..85eed3c 100644 --- a/org.tizen.dynamicanalyzer.workbench/build.properties +++ b/org.tizen.dynamicanalyzer.workbench/build.properties @@ -1,11 +1,14 @@ -source.. = src/ -output.. = bin/ -bin.includes = plugin.xml,\ - META-INF/,\ - .,\ - about.ini,\ - about.mappings,\ - about.properties,\ - plugin.properties,\ - plugin_customization.ini,\ - icons/ +output.. = bin/ +bin.includes = plugin.xml,\ + META-INF/,\ + .,\ + about.ini,\ + about.mappings,\ + about.properties,\ + plugin.properties,\ + plugin_customization.ini,\ + icons/,\ + LayoutManagerE4.e4xmi,\ + WorkbenchAppModel.e4xmi,\ + Application.e4xmi +source.. = src/ diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/feature b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/feature old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/setting b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/setting index 26c4351..2a8f16e 100644 --- a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/setting +++ b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/setting @@ -7,15 +7,15 @@ Options Selected Feature List|5002:0 Default Feature List|2|3|103 Total Overhead Range|1000000|3000000|7000000|15000000 mobile|Protocol Version|4.0 -mobile|Available Template List|1|2|3|4|5|6|7|8|9|10 +mobile|Available Template List|1|2|3|4|5|6|7|8|9|10|11 mobile|Selected Template|1 mobile|Available Feature List|1|1000|4|5|6|7|8|9|100|101|1001|102|200|201|202|203|204|206 mobile|Selected Feature List|1|5|1000:1000|100|101|1001:10 mobile|Available Chart List|CPU|CPU core|CPU frequency|Heap allocation|Process Size|Memory|Screenshot|UI event|Disk IO|Network IO|Device|Energy wearable|Protocol Version|3.0 -wearable|Available Template List|1|2|3|4|5|6|7|8|9|10 +wearable|Available Template List|1|2|3|4|5|6|7|8|9|10|11 wearable|Selected Template|1 -wearable|Available Feature List|1|1000|4|5|6|7|8|9|100|101|1001|102|200|201|202|203|204 +wearable|Available Feature List|1|1000|4|5|6|7|8|9|100|101|1001|102|200|201|202|203|204|206 wearable|Selected Feature List|1|5|1000:1000|100|101|1001:10 wearable|Available Chart List|CPU|CPU core|CPU frequency|Heap allocation|Process Size|Memory|Screenshot|UI event|Disk IO|Network IO|Device|Energy tv|Protocol Version|3.0 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/template b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/template index 307eb6f..24fade9 100644 --- a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/template +++ b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/config/template @@ -7,4 +7,5 @@ 7|Network|1|7|1000:1000|202 8|OpenGL|1|5|1000:1000|100|203 9|Energy|1|5|4|9|1000:1000 -10|Custom +10|UI Hierarchy|206 +11|Custom \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/Shortcut.vbs b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/Shortcut.vbs old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/cpio.exe b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/cpio.exe old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/dd.exe b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/dd.exe old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/debuginfo.bat b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/debuginfo.bat old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/gzip.exe b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/gzip.exe old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/libiconv2.dll b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/libiconv2.dll old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/libintl3.dll b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/libintl3.dll old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/md5sum.exe b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/md5sum.exe old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/od.exe b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/od.exe old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/rpm2cpio.bat b/org.tizen.dynamicanalyzer.workbench/dynamic-analyzer/tool/rpm2cpio.bat old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/dynamicanalyzer.product b/org.tizen.dynamicanalyzer.workbench/dynamicanalyzer.product old mode 100755 new mode 100644 index 6b8b93d..6984936 --- a/org.tizen.dynamicanalyzer.workbench/dynamicanalyzer.product +++ b/org.tizen.dynamicanalyzer.workbench/dynamicanalyzer.product @@ -1,56 +1,73 @@ - - - - - - - - - %AboutDescription - - - - - - - - -data @noDefault + + + + + + + + + %AboutDescription + + + + + + + + -data @noDefault + -XX:MaxPermSize=64m -Xms256m -Xmx512m -XX:+UseParNewGC --XX:+UseConcMarkSweepGC - -XstartOnFirstThread -Dorg.eclipse.swt.internal.carbon.smallFonts - - - - - - - - - - - - - - - - org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6 - - - - - - - - - - - - - - - - - +-XX:+UseConcMarkSweepGC + + -XstartOnFirstThread -Dorg.eclipse.swt.internal.carbon.smallFonts + + + + + + + + + + + + + + + + + org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/org.tizen.dynamicanalyzer.workbench/plugin.properties b/org.tizen.dynamicanalyzer.workbench/plugin.properties index c20970b..7779482 100644 --- a/org.tizen.dynamicanalyzer.workbench/plugin.properties +++ b/org.tizen.dynamicanalyzer.workbench/plugin.properties @@ -4,7 +4,7 @@ pluginName=Dynamic Analyzer Workbench providerName=Samsung Electronics #Product name, Application Name -DynamicAnalyzer=Tizen Dynamic Analyzer +DynamicAnalyzer=Dynamic Analyzer #Perspective name MainPerspective=MainPerspective \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer.workbench/plugin.xml b/org.tizen.dynamicanalyzer.workbench/plugin.xml index 57a2541..eb37054 100644 --- a/org.tizen.dynamicanalyzer.workbench/plugin.xml +++ b/org.tizen.dynamicanalyzer.workbench/plugin.xml @@ -5,12 +5,14 @@ - + + @@ -18,18 +20,14 @@ application="org.tizen.dynamicanalyzer.workbench.application" name="%DynamicAnalyzer"> + name="applicationXMI" + value="org.tizen.dynamicanalyzer.workbench/Application.e4xmi"> + name="appName" + value="%DynamicAnalyzer"> - - @@ -37,8 +35,13 @@ name="aboutText" value="%AboutDescription"> + + + - - + diff --git a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/common/path/PathManager.java b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/common/path/PathManager.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/Application.java b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/Application.java old mode 100755 new mode 100644 index aa606ee..a09db05 --- a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/Application.java +++ b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/Application.java @@ -66,7 +66,6 @@ public class Application implements IApplication { @Override public Object start(IApplicationContext context) throws Exception { Display display = PlatformUI.createDisplay(); - // set workspace directory for dynamic analyzer // this work must be done first before any other work. Location instanceLoc = Platform.getInstanceLocation(); @@ -140,7 +139,8 @@ public class Application implements IApplication { display.dispose(); return IApplication.EXIT_OK; } - + + /// Entry to AnalyzerPlugin int returnCode = PlatformUI.createAndRunWorkbench(display, new ApplicationWorkbenchAdvisor()); @@ -159,6 +159,7 @@ public class Application implements IApplication { return; } final IWorkbench workbench = PlatformUI.getWorkbench(); + if(workbench == null) return; final Display display = workbench.getDisplay(); display.syncExec(new Runnable() { @Override diff --git a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationActionBarAdvisor.java b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationActionBarAdvisor.java index b1c1d58..b5a4a0e 100644 --- a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationActionBarAdvisor.java +++ b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationActionBarAdvisor.java @@ -27,23 +27,48 @@ package org.tizen.dynamicanalyzer.workbench; +import org.eclipse.core.runtime.IExtension; +import org.eclipse.jface.action.IContributionItem; import org.eclipse.jface.action.IMenuManager; import org.eclipse.ui.IWorkbenchWindow; import org.eclipse.ui.application.ActionBarAdvisor; import org.eclipse.ui.application.IActionBarConfigurer; +import org.eclipse.ui.internal.WorkbenchPlugin; +import org.eclipse.ui.internal.registry.ActionSetRegistry; +import org.eclipse.ui.internal.registry.IActionSetDescriptor; public class ApplicationActionBarAdvisor extends ActionBarAdvisor { - + + private static final String[] actionSetId = new String[] { "org.eclipse.search.searchActionSet", "org.eclipse.ui.externaltools.ExternalToolsSet"}; //$NON-NLS-1$ + public ApplicationActionBarAdvisor(IActionBarConfigurer configurer) { super(configurer); + removeUnWantedActions(); } @Override protected void fillMenuBar(IMenuManager menuBar) { + } @Override protected void makeActions(IWorkbenchWindow window) { } + + private void removeUnWantedActions() { + ActionSetRegistry asr = WorkbenchPlugin.getDefault().getActionSetRegistry(); + IActionSetDescriptor[] actionSets = asr.getActionSets(); + + IExtension ext = null; + for (IActionSetDescriptor actionSet : actionSets) { + for (String element : actionSetId) { + System.out.println(element); + if (element.equals(actionSet.getId())) { + ext = actionSet.getConfigurationElement().getDeclaringExtension(); + asr.removeExtension(ext, new Object[] { actionSet }); + } + } + } + } } diff --git a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationWorkbenchWindowAdvisor.java b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationWorkbenchWindowAdvisor.java old mode 100755 new mode 100644 index 08fb944..2057c9d --- a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationWorkbenchWindowAdvisor.java +++ b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/ApplicationWorkbenchWindowAdvisor.java @@ -66,18 +66,18 @@ public class ApplicationWorkbenchWindowAdvisor extends WorkbenchWindowAdvisor { ExecutionCallbackManager .createCallbackList(ExecutionCallbackManager.WINDOWADVISOR_PREWINDOWCLOSE); } - + /* @Override public ActionBarAdvisor createActionBarAdvisor( IActionBarConfigurer configurer) { return new ApplicationActionBarAdvisor(configurer); } - + */ @Override public void createWindowContents(Shell shell) { // customize workbench window // create basic composites - LayoutManager.createComposite(getWindowConfigurer(), shell); + LayoutManager.createComposite(shell); } @Override @@ -94,8 +94,10 @@ public class ApplicationWorkbenchWindowAdvisor extends WorkbenchWindowAdvisor { IWorkbenchWindowConfigurer configurer = getWindowConfigurer(); configurer.setInitialSize(new Point(width, height)); - configurer.setShowStatusLine(false); + configurer.setShowStatusLine(true); configurer.setShellStyle(SWT.SHELL_TRIM); + configurer.setTitle("Dynamic Analyzer"); + configurer.setShowCoolBar(false); configurer.setShowFastViewBars(false); } diff --git a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/LayoutManager.java b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/LayoutManager.java index 2bb0f59..fc740bc 100644 --- a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/LayoutManager.java +++ b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/LayoutManager.java @@ -32,9 +32,6 @@ import org.eclipse.swt.layout.FormAttachment; import org.eclipse.swt.layout.FormData; import org.eclipse.swt.layout.FormLayout; import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.application.IWorkbenchWindowConfigurer; public class LayoutManager { private static Composite baseComposite = null; @@ -47,18 +44,17 @@ public class LayoutManager { public static Composite getBaseComposite() { return baseComposite; } - - public static void createComposite(IWorkbenchWindowConfigurer configurer, - Shell shell) { + + public static Composite createComposite(Composite parent) { // Sets shell layout. - final FillLayout shellLayout = new FillLayout(); + final FillLayout shellLayout = new FillLayout(SWT.VERTICAL); shellLayout.marginHeight = 0; shellLayout.marginWidth = 1; - shell.setLayout(shellLayout); - + parent.setLayout(shellLayout); + // create base composite - baseComposite = new Composite(shell, SWT.NONE); + baseComposite = new Composite(parent, SWT.NONE); baseComposite.setLayout(new FormLayout()); // create toolbar composite @@ -66,25 +62,26 @@ public class LayoutManager { toolbarComposite.setLayout(new FormLayout()); // create page composite with base composite - Control page = configurer.createPageComposite(baseComposite); - if (null != page) { - // layout each composite - FormData data = new FormData(); - data.top = new FormAttachment(0, 0); - data.left = new FormAttachment(0, 0); - data.right = new FormAttachment(100, 0); - data.height = 38; - toolbarComposite.setLayoutData(data); - - data = new FormData(); - data.top = new FormAttachment(toolbarComposite, 0, SWT.BOTTOM); - data.left = new FormAttachment(0, 0); - data.right = new FormAttachment(100, 0); - data.bottom = new FormAttachment(100, 0); - page.setLayoutData(data); - - configurer.getWindow().getShell().layout(true); - ((Composite) page).layout(true); - } + // create main area composite with base composite + Composite mainComposite = new Composite(baseComposite, SWT.NONE); + mainComposite.setLayout(new FillLayout()); + + // layout each composite + FormData data = new FormData(); + data.top = new FormAttachment(0, 0); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(100, 0); + data.height = 38; + toolbarComposite.setLayoutData(data); + + data = new FormData(); + data.top = new FormAttachment(toolbarComposite, 0, SWT.BOTTOM); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(100, 0); + data.bottom = new FormAttachment(100, 0); + mainComposite.setLayoutData(data); + + return mainComposite; + } } diff --git a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/SingletonFocusManager.java b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/SingletonFocusManager.java index 2434144..3bcac2d 100644 --- a/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/SingletonFocusManager.java +++ b/org.tizen.dynamicanalyzer.workbench/src/org/tizen/dynamicanalyzer/workbench/SingletonFocusManager.java @@ -39,12 +39,8 @@ import java.io.RandomAccessFile; import java.nio.channels.FileChannel; import java.nio.channels.FileLock; -import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Shell; -import org.eclipse.ui.IWorkbench; -import org.eclipse.ui.IWorkbenchWindow; -import org.eclipse.ui.PlatformUI; import org.tizen.dynamicanalyzer.common.path.PathConstants; import org.tizen.dynamicanalyzer.common.path.PathManager; import org.tizen.dynamicanalyzer.util.CommonUtil; diff --git a/org.tizen.dynamicanalyzer/.classpath b/org.tizen.dynamicanalyzer/.classpath index 5ac0602..096a2bd 100644 --- a/org.tizen.dynamicanalyzer/.classpath +++ b/org.tizen.dynamicanalyzer/.classpath @@ -4,7 +4,7 @@ - + diff --git a/org.tizen.dynamicanalyzer/.settings/org.eclipse.jdt.core.prefs b/org.tizen.dynamicanalyzer/.settings/org.eclipse.jdt.core.prefs index 4d1d94e..d17b672 100644 --- a/org.tizen.dynamicanalyzer/.settings/org.eclipse.jdt.core.prefs +++ b/org.tizen.dynamicanalyzer/.settings/org.eclipse.jdt.core.prefs @@ -1,8 +1,12 @@ -#Fri Oct 01 12:23:52 KST 2010 eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.7 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 \ No newline at end of file +org.eclipse.jdt.core.compiler.source=1.7 diff --git a/org.tizen.dynamicanalyzer/META-INF/MANIFEST.MF b/org.tizen.dynamicanalyzer/META-INF/MANIFEST.MF index b116b29..468a1fe 100644 --- a/org.tizen.dynamicanalyzer/META-INF/MANIFEST.MF +++ b/org.tizen.dynamicanalyzer/META-INF/MANIFEST.MF @@ -12,7 +12,7 @@ Require-Bundle: org.eclipse.ui, org.tizen.dynamicanalyzer.appearance;bundle-version="1.0.0", org.tizen.dynamicanalyzer.widgets;bundle-version="1.0.0", org.tizen.dynamicanalyzer.workbench;bundle-version="1.0.0" -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Bundle-Activator: org.tizen.dynamicanalyzer.common.AnalyzerPlugin Bundle-ActivationPolicy: lazy Bundle-ClassPath: ., @@ -31,3 +31,4 @@ Import-Package: junit.framework;version="4.8.2", org.tizen.sdblib.receiver, org.tizen.sdblib.service, org.tizen.sdblib.util +Export-Package: org.tizen.dynamicanalyzer.listeners diff --git a/org.tizen.dynamicanalyzer/ecs/gen.sh b/org.tizen.dynamicanalyzer/ecs/gen.sh old mode 100644 new mode 100755 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/AnalyzerManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/AnalyzerManager.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/AnalyzerShellCommands.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/AnalyzerShellCommands.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/DALogExport.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/DALogExport.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/DAResult.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/common/DAResult.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/BaseCommunicator.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/BaseCommunicator.java old mode 100755 new mode 100644 index e9b57a8..26ea202 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/BaseCommunicator.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/BaseCommunicator.java @@ -48,6 +48,7 @@ import org.tizen.dynamicanalyzer.protocol.DebugLog; import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.protocol.ProtocolConstants; import org.tizen.dynamicanalyzer.protocol.p30.Communicator30; +import org.tizen.dynamicanalyzer.protocol.p30_uihv.Communicator30_UIHV; import org.tizen.dynamicanalyzer.protocol.p40.Communicator40; import org.tizen.dynamicanalyzer.protocol.p41.Communicator41; import org.tizen.dynamicanalyzer.ui.info.screenshot.EmulatorScreenshot; @@ -366,6 +367,13 @@ public class BaseCommunicator { parser.getInt(); // for return code version = parser.getString(); + + // This routine is needed to support backward compatibility for UIHV. + // We distinguish legacy(3.0) between new(3.0 + UIHV) protocol + // from whether version message "3.0" is returned. + if (version.equals(Protocol.VERSION_30.toString())) { + version = Protocol.VERSION_30_UIHV.toString(); + } } } else { // legacy(3.0), version message treated as keep alive message @@ -404,8 +412,12 @@ public class BaseCommunicator { Protocol version = Protocol.getVersion(protocolVersion); switch (version) { case VERSION_30: + case VERSION_30A: subCommunicator = new Communicator30(this); break; + case VERSION_30_UIHV: + subCommunicator = new Communicator30_UIHV(this); + break; case VERSION_40: subCommunicator = new Communicator40(this); break; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/CommunicatorUtils.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/CommunicatorUtils.java old mode 100755 new mode 100644 index 99b4a93..2adb612 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/CommunicatorUtils.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/CommunicatorUtils.java @@ -37,6 +37,7 @@ import org.tizen.dynamicanalyzer.common.DAResult.ErrorCode; import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.sdblib.IDevice; import org.tizen.sdblib.IShellOutputReceiver; +import org.tizen.sdblib.PlatformCapability; import org.tizen.sdblib.exception.SdbCommandRejectedException; import org.tizen.sdblib.exception.ShellCommandUnresponsiveException; import org.tizen.sdblib.exception.TimeoutException; @@ -83,8 +84,13 @@ public class CommunicatorUtils { boolean availability = false; try { - availability = device.becomeSuperUser(true); - device.becomeSuperUser(false); + PlatformCapability capability = device.getPlatformCapability(); + String rootPerm = capability.getSdbdRootPerm(); + if (rootPerm.equals(PlatformCapability.DISABLED)) { + availability = false; + } else { + availability = true; + } } catch (TimeoutException e) { Logger.exception(e); } catch (SdbCommandRejectedException e) { diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DACommunicator.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DACommunicator.java old mode 100755 new mode 100644 index 41b66be..a062f59 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DACommunicator.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DACommunicator.java @@ -111,7 +111,11 @@ public class DACommunicator { long filesize = -1; if (cmdResultMultiLines.size() > 0) { - filesize = Long.parseLong(cmdResultMultiLines.get(0)); + try { + filesize = Long.parseLong(cmdResultMultiLines.get(0)); + } catch (NumberFormatException e) { + Logger.exception(e); + } } if (filesize > 0 && filesize < DALimit.MAX_DAEMON_LOG_SIZE) { @@ -435,7 +439,7 @@ public class DACommunicator { * Request all of EFL UI objects(evas, elementary, edje) information at request time. * Information includes (hierarchy, properties, rendering time if parameter is true). * Information is received through data channel(MSG_UI_HIERARCHY). - * + * * @param requestRenderTime * if true, request rendering time also. * @return SUCCESS, @@ -458,7 +462,7 @@ public class DACommunicator { /** * Request screenshot of a specific Evas Object. - * + * * @param uiObject * specific Evas object * @return SUCCESS @@ -470,8 +474,8 @@ public class DACommunicator { * @throws InterruptedException * @throws UnsupportedProtocolException */ - public static DAResult requestUIScreenshot(long uiAddress) - throws InterruptedException, UnsupportedProtocolException { + public static DAResult requestUIScreenshot(long uiAddress) throws InterruptedException, + UnsupportedProtocolException { DeviceInfo curDev = Global.getCurrentDeviceInfo(); if (curDev != null) { return curDev.getCommunicator().getSubCommunicator() @@ -484,7 +488,7 @@ public class DACommunicator { /** * During SWAP collect informations for MSG_GET_UI_HIERARCHY, this method make SWAP stop collect * information. If SWAP is redrawing objects, It should be stopped. - * + * * @return SUCCESS * @return ERR_NO_DEVICE * @return ERR_RECEIVE_ACK_FAIL diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DeviceManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/DeviceManager.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/SubCommunicator.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/communicator/SubCommunicator.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/control/ApplistManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/control/ApplistManager.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/handlers/UIAction.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/handlers/UIAction.java index ccbfa7c..001b395 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/handlers/UIAction.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/handlers/UIAction.java @@ -159,6 +159,20 @@ public class UIAction { }); } + public static void showWarning(final String title, final String message) { + Display.getDefault().asyncExec(new Runnable() { + @Override + public void run() { + Shell shell = WorkbenchUtil.getWorkbenchWindow().getShell(); + DADialog dialog = new DADialog(shell, SWT.NONE); + dialog.setIcon(ImageResources.DIALOG_WARNING_ICON); + dialog.setTitleText(title); + dialog.setMessage(message); + dialog.open(); + } + }); + } + public static void showWarning(final DAResult result) { showWarning(result.getMessage() + CommonConstants.SPACE + CommonConstants.OPEN_BRACKET + result.getErrorNumber() + CommonConstants.CLOSE_BRACKET); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/listeners/AnalyzerPerspectiveListener.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/listeners/AnalyzerPerspectiveListener.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/model/FilterProperty.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/model/FilterProperty.java new file mode 100644 index 0000000..91866e9 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/model/FilterProperty.java @@ -0,0 +1,56 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Seokgil Kang + * Juyoung Kim + * WooJin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.model; + +import org.tizen.dynamicanalyzer.constant.CommonConstants; + +public class FilterProperty { + private int columnIndex; + private String keyWord; + + public FilterProperty() { + columnIndex = -1; + keyWord = CommonConstants.EMPTY; + } + + public int getColumnIndex() { + return columnIndex; + } + + public String getKeyWord() { + return keyWord; + } + + public void setColumnIndex(int index) { + columnIndex = index; + } + + public void setKeyWord(String keyWord) { + this.keyWord = keyWord; + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.java old mode 100755 new mode 100644 index 422e6a7..8ecc2da --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.java @@ -149,9 +149,10 @@ public class AnalyzerLabels extends NLS { public static String LICENSE_DIALOG_NOT_FOUND; public static String ABOUT_DIALOG_TITLE; - public static String ABOUT_DIALOG_BUILD_TIME_TAB; + public static String ABOUT_DIALOG_BUILD_ID_TAB; public static String ABOUT_DIALOG_VERSION_TAB; - public static String ABOUT_DIALOG_DA_VERSION_TAB; + public static String ABOUT_DIALOG_VISIT; + public static String ABOUT_DIALOG_SITE_URL; public static String ABOUT_DIALOG_LICENSE; public static String CONFIGURATION_DIALOG_AUTO_RANGE; @@ -182,6 +183,13 @@ public class AnalyzerLabels extends NLS { public static String FIND_DLG_OPTION; public static String FIND_DLG_CASE_SENSITIVE; public static String FIND_DLG_WHOLE_WORD; + + public static String FILTER_DLG_TITLE_PREFIX; + public static String FILTER_DLG_TITLE_POSTFIX; + public static String FILTER_DLG_ADD_BUTTON; + public static String FILTER_DLG_CLEAR_BUTTON; + public static String FILTER_DLG_CLEAR_MESSAGE; + public static String FILTER_DLG_KEYWORD_VERIFICATION_MESSAGE; public static String SAVE_TRACE_DLG_SAVE_FILE_NAME; public static String SAVE_FAILED; @@ -223,6 +231,10 @@ public class AnalyzerLabels extends NLS { public static String DETAIL_INFORMATION_APPLICATION_NAME; public static String DETAIL_INFORMATION_APPLICATION_EXEC_PATH; + // advanced menu text + public static String ADVANCED_MENU_SEARCH; + public static String ADVANCED_MENU_FILTER; + static { NLS.initializeMessages(BUNDLE_NAME, AnalyzerLabels.class); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.properties b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.properties old mode 100755 new mode 100644 index dbdffd5..16ec934 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.properties +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/AnalyzerLabels.properties @@ -27,17 +27,17 @@ CONNECT=Connect CONNECTING=Connecting #Setting menu -ABOUT=About Tizen Dynamic Analyzer [F1] +ABOUT=About Dynamic Analyzer [F1] SETTING=Settings [F2] VIEW_SOURCE=View source [F3] -ABOUT_MAC=About Tizen Dynamic Analyzer [fn + F1] +ABOUT_MAC=About Dynamic Analyzer [fn + F1] SETTING_MAC=Settings [fn + F2] VIEW_SOURCE_MAC=View source [fn + F3] -#ABOUT_MAC=About Tizen Dynamic Analyzel; +#ABOUT_MAC=About Dynamic Analyzer; -ABOUT_TITLE=About Tizen Dynamic Analyzer +ABOUT_TITLE=About Dynamic Analyzer LICENSE=License CONFIGURATION=Configuration WELCOME=Welcome @@ -113,10 +113,11 @@ COOLBAR_AREA_CONFIGURATION_OPTION=Options LICENSE_DIALOG_NOT_FOUND=License file not found -ABOUT_DIALOG_TITLE=Tizen Dynamic Analyzer -ABOUT_DIALOG_BUILD_TIME_TAB=Build time\t: -ABOUT_DIALOG_VERSION_TAB=SDK Version\t: -ABOUT_DIALOG_DA_VERSION_TAB=DA Version\t: +ABOUT_DIALOG_TITLE=Tizen SDK +ABOUT_DIALOG_BUILD_ID_TAB=Build id\t: +ABOUT_DIALOG_VERSION_TAB=Version\t: +ABOUT_DIALOG_VISIT=Visit +ABOUT_DIALOG_SITE_URL=https://developer.tizen.org ABOUT_DIALOG_LICENSE=License CONFIGURATION_DIALOG_AUTO_RANGE=Auto Range View Transmit @@ -156,6 +157,13 @@ FIND_DLG_DIRECTION_BACKWARD=Back FIND_DLG_OPTION=Option : FIND_DLG_CASE_SENSITIVE=Case sensitive FIND_DLG_WHOLE_WORD=Whole word + +FILTER_DLG_TITLE_PREFIX=Filter from +FILTER_DLG_TITLE_POSTFIX= table +FILTER_DLG_ADD_BUTTON=Add +FILTER_DLG_CLEAR_BUTTON=Clear +FILTER_DLG_CLEAR_MESSAGE=Clear filter setting?\nIf you click 'Ok', All settings will be deleted. +FILTER_DLG_KEYWORD_VERIFICATION_MESSAGE=Please enter a keyword. SAVE_TRACE_DLG_SAVE_FILE_NAME=Enter save file name SAVE_FAILED=Failed to save the tracing result @@ -187,3 +195,6 @@ DETAIL_INFORMATION_PACKAGE_VERSION=Package Version : DETAIL_INFORMATION_PACKAGE_INSTALL_TIME=Package Installed Time : DETAIL_INFORMATION_APPLICATION_NAME=Application Name : DETAIL_INFORMATION_APPLICATION_EXEC_PATH=Application Exec Path : + +ADVANCED_MENU_SEARCH=Search +ADVANCED_MENU_FILTER=Filter diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.java index 6ba7bbf..be4910f 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.java @@ -76,6 +76,7 @@ public class ConfigureLabels extends NLS { public static String TEMPLATE_NAME_NETWORK; public static String TEMPLATE_NAME_OPEN_GL; public static String TEMPLATE_NAME_ENERGY; + public static String TEMPLATE_NAME_UI_HIERARCHY; public static String TEMPLATE_NAME_CUSTOM; public static String TEMPLATE_DESCRIPTION_BOTTLENECK; @@ -87,6 +88,7 @@ public class ConfigureLabels extends NLS { public static String TEMPLATE_DESCRIPTION_NETWORK; public static String TEMPLATE_DESCRIPTION_OPEN_GL; public static String TEMPLATE_DESCRIPTION_ENERGY; + public static String TEMPLATE_DESCRIPTION_UI_HIERARCHY; public static String TEMPLATE_DESCRIPTION_CUSTOM; public static String FEATURE_NAME_SYSTEM; // 3.0 only diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.properties b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.properties index 53495e9..f563713 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.properties +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/ConfigureLabels.properties @@ -43,6 +43,7 @@ TEMPLATE_NAME_WAIT_STATUS=Wait Status TEMPLATE_NAME_NETWORK=Network TEMPLATE_NAME_OPEN_GL=OpenGL TEMPLATE_NAME_ENERGY=Energy +TEMPLATE_NAME_UI_HIERARCHY=UI Hierarchy TEMPLATE_NAME_CUSTOM=Custom TEMPLATE_DESCRIPTION_BOTTLENECK=This template shows where can be the most bottleneck point while you are using your program. With the CPU and process chart, you can easily find where the application uses the CPU a lot. And the function profiling and call trace information shows the bottleneck point with the view of function level. @@ -54,6 +55,7 @@ TEMPLATE_DESCRIPTION_WAIT_STATUS=This template shows various information that ca TEMPLATE_DESCRIPTION_NETWORK=This template shows the TCP/UDP network activity of the glibc socket. The Network chart shows each session information. And you can check which API has been called in each session and can see the transmitted data, too. TEMPLATE_DESCRIPTION_OPEN_GL=This template shows a lot of detailed information of the openGL layer. It shows the FPS, render state, openGL calls, statistics and redundant usage of the API. These help you to optimize the performance of your application. We are supporting OpenGL ES 2.0 and EvasGL, now. TEMPLATE_DESCRIPTION_ENERGY=This template inform you of power consumption of target device. you can see this information from Energy chart in Timeline page. Energy chart shows usage of Flash memory, CPU, LCD. +TEMPLATE_DESCRIPTION_UI_HIERARCHY=This template shows the information of EFL UI objects (Evas, Elementary, Edje). You can see the hierarchy relationship of all UI objects and the detailed information of each UI object. TEMPLATE_DESCRIPTION_CUSTOM=This template can be configured by selecting the desired features. If you change the feature in the other template will change custom template. FEATURE_NAME_SYSTEM=System diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/GLPageLabels.properties b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/GLPageLabels.properties index 34ba704..c66da47 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/GLPageLabels.properties +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/GLPageLabels.properties @@ -60,7 +60,7 @@ GL_STATISTICS_VIEW_COUNT=Count GL_STATISTICS_VIEW_API_TYPE=API type GL_REDUNDANT_TITLE=Redundant -GL_REDUNDANT_VIEW_COUNT= count +GL_REDUNDANT_VIEW_COUNT= Count GL_REDUNDANT_VIEW_ELAPSED_TIME=Elapsed time GL_REDUNDANT_VIEW_API_NAME=API GL_REDUNDANT_VIEW_PARAMETER=Parameter diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.java old mode 100755 new mode 100644 index aa3f13a..e5c30ee --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.java @@ -41,10 +41,10 @@ public class MemoryPageLabels extends NLS { public static String MEMORY_CHART_SYSTEM_MEMORY; public static String MEMORY_MEMORYMAP_LIBNAME; + public static String MEMORY_MEMORYMAP_ADDRESS; public static String MEMORY_MEMORYMAP_ADDRESS_LOW; public static String MEMORY_MEMORYMAP_ADDRESS_HIGH; public static String MEMORY_MEMORYMAP_SIZE; - public static String MEMORY_MEMORYMAP_TYPE; static { // initialize resource bundle diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.properties b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.properties old mode 100755 new mode 100644 index 8ac7308..a0d6eca --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.properties +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/MemoryPageLabels.properties @@ -30,10 +30,10 @@ MEMORY_ALLOCATION_TRACE_VIEW_LIBRARY=Library MEMORY_ALLOCATION_TRACE_VIEW_CALLER_FUNCTION=Caller Function MEMORY_MEMORYMAP_LIBNAME=Name +MEMORY_MEMORYMAP_ADDRESS=Address MEMORY_MEMORYMAP_ADDRESS_LOW=Low-address MEMORY_MEMORYMAP_ADDRESS_HIGH=High-address MEMORY_MEMORYMAP_SIZE=Size -MEMORY_MEMORYMAP_TYPE=Type MEMORY_CHART_HEAP_MEMORY=Heap allocation MEMORY_CHART_PROCESS_MEMORY=Process Size diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.java index 4473aef..8ca855e 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.java @@ -41,6 +41,7 @@ public class SummaryLabels extends NLS { public static String FAILED_API_LIST_VIEW_TIME; public static String FAILED_API_LIST_VIEW_ERROR_CODE; public static String FAILED_API_LIST_VIEW_ERROR_DESCRIPTION; + public static String FAILED_API_LIST_UNDEFINED_ERROR_NUMBER; public static String FUNCTION_USAGE_PROFILER_APPLICATION; public static String FUNCTION_USAGE_PROFILER_DEPENDENT_LIB; @@ -58,6 +59,8 @@ public class SummaryLabels extends NLS { public static String FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_ELAPSED_TIME; public static String FUNCTION_USER_PROFILING_VIEW_FILE; public static String FUNCTION_USER_PROFILING_VIEW_LINE_NUMBER; + public static String FUNCTION_USER_PROFILING_VIEW_EXCLUSIVE_PREFIX; + public static String FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_PREFIX; public static String WARNING_CASE_BRIEF_DUPLICATE; public static String WARNING_CASE_BRIEF_NO_OPERATION; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.properties b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.properties index 47bd209..5d2eddd 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.properties +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/SummaryLabels.properties @@ -7,6 +7,7 @@ FAILED_API_LIST_VIEW_RETURN=Return FAILED_API_LIST_VIEW_TIME=Time FAILED_API_LIST_VIEW_ERROR_CODE=Error code FAILED_API_LIST_VIEW_ERROR_DESCRIPTION=Error description +FAILED_API_LIST_UNDEFINED_ERROR_NUMBER=Undefined error number FUNCTION_USAGE_PROFILER_APPLICATION=Application FUNCTION_USAGE_PROFILER_DEPENDENT_LIB=Dependent library @@ -24,6 +25,8 @@ FUNCTION_USER_PROFILING_VIEW_EXCLUSIVE_ELAPSED_TIME=Exclusive time FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_ELAPSED_TIME=Inclusive time FUNCTION_USER_PROFILING_VIEW_FILE=File FUNCTION_USER_PROFILING_VIEW_LINE_NUMBER=Line number +FUNCTION_USER_PROFILING_VIEW_EXCLUSIVE_PREFIX=Ex- +FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_PREFIX=In- WARNING_CASE_BRIEF_DUPLICATE= Duplicate file open. WARNING_CASE_BRIEF_NO_OPERATION= File closed without using it. diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/UserErrorWarningLabels.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/UserErrorWarningLabels.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/UserErrorWarningLabels.properties b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/nl/UserErrorWarningLabels.properties old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/BinaryInfo.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/BinaryInfo.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/DeviceStatusInfo.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/DeviceStatusInfo.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/Project.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/project/Project.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/Protocol.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/Protocol.java index abdae32..f2a9365 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/Protocol.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/Protocol.java @@ -31,6 +31,7 @@ import java.util.Map; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.protocol.p30.ProtocolConfig30; +import org.tizen.dynamicanalyzer.protocol.p30_uihv.ProtocolConfig30_UIHV; import org.tizen.dynamicanalyzer.protocol.p40.ProtocolConfig40; import org.tizen.dynamicanalyzer.protocol.p41.ProtocolConfig41; import org.tizen.dynamicanalyzer.setting.Feature; @@ -38,6 +39,8 @@ import org.tizen.dynamicanalyzer.setting.Feature; public enum Protocol { VERSION_UNKNOWN(CommonConstants.EMPTY), VERSION_30("3.0"), + VERSION_30A("3.0 a"), + VERSION_30_UIHV("3.0_UIHV"), VERSION_40("4.0"), VERSION_41("4.1"); @@ -73,6 +76,8 @@ public enum Protocol { tempMap.put(0x0016, "MSG_WEB_FUNCTION_EXIT"); tempMap.put(0x0019, "MSG_APP_STARTUP"); tempMap.put(0x001A, "MSG_WEB_APP_STARTUP"); + tempMap.put(0x0020, "MSG_FBI"); + tempMap.put(0x0021, "MSG_UI_HIERARCHY"); // data probe message id tempMap.put(0x0101, "MSG_PROBE_MEMORY"); @@ -117,14 +122,18 @@ public enum Protocol { switch (protocolVersion) { case VERSION_30: + case VERSION_30A: configs = ProtocolConfig30.getProtocolConfig(feature); break; + case VERSION_30_UIHV: + configs = ProtocolConfig30_UIHV.getProtocolConfig(feature); + break; case VERSION_40: configs = ProtocolConfig40.getProtocolConfig(feature); break; case VERSION_41: configs = ProtocolConfig41.getProtocolConfig(feature); - break; + break; default: // unknown protocol throw new UnknownProtocolException(); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/ApplicationInst30.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/ApplicationInst30.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/FunctionInst30.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/FunctionInst30.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/LibraryInst30.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30/LibraryInst30.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/Communicator30_UIHV.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/Communicator30_UIHV.java new file mode 100644 index 0000000..b523137 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/Communicator30_UIHV.java @@ -0,0 +1,158 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2013 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Jaewon Lim + * Woojin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.protocol.p30_uihv; + +import java.io.File; +import java.util.Set; + +import org.tizen.dynamicanalyzer.common.AnalyzerConstants; +import org.tizen.dynamicanalyzer.common.DAResult; +import org.tizen.dynamicanalyzer.common.DAResult.ErrorCode; +import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.communicator.AckMessage; +import org.tizen.dynamicanalyzer.communicator.BaseCommunicator; +import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.communicator.ProtocolSerializer; +import org.tizen.dynamicanalyzer.communicator.UnsupportedProtocolException; +import org.tizen.dynamicanalyzer.control.IProgress; +import org.tizen.dynamicanalyzer.protocol.p30.Communicator30; +import org.tizen.dynamicanalyzer.setting.Feature; +import org.tizen.dynamicanalyzer.setting.SettingDataManager; +import org.tizen.dynamicanalyzer.setting.TargetData; +import org.tizen.dynamicanalyzer.swap.communicator.SwapErrorCode; +import org.tizen.dynamicanalyzer.util.Logger; +import org.tizen.dynamicanalyzer.utils.DownloadContentfileManager; + +public class Communicator30_UIHV extends Communicator30 { + + public Communicator30_UIHV(BaseCommunicator parent) { + super(parent); + } + + @Override + public DAResult sendConfigurationMessage(IProgress progress) { + // send config message + ProtocolSerializer ps = new ProtocolSerializer(); + ps.setMessageID(ProtocolConstant30_UIHV.MSG_CONFIG); + + // set feature flag value + Set selectedFeatures = SettingDataManager.INSTANCE.getSelectedFeatureSet(); + byte[] featureFlag = ProtocolConfig30_UIHV.getFeatureFlagValue(selectedFeatures); + ps.putByteArray(featureFlag); + + // set sampling period value + TargetData target = SettingDataManager.INSTANCE.getConnectedTarget(); + int systemPeriod = target.getSelectedFeatureValue(Feature.SYSTEM_SAMPLING_RATE); + if (systemPeriod < 0) { + systemPeriod = Feature.SYSTEM_SAMPLING_RATE.getData().getDefaultValue(); + } + int samplingPeriod = target.getSelectedFeatureValue(Feature.FUNCTION_SAMPLING_RATE); + if (samplingPeriod < 0) { + samplingPeriod = Feature.FUNCTION_SAMPLING_RATE.getData().getDefaultValue(); + } + ps.putInt(systemPeriod); + ps.putInt(samplingPeriod); + + byte[] msg = ps.toByteArray(); + + AckMessage result = parent.handleControlMessage(msg); + + if (result != null && result.isSuccess() + && result.isCorrectID(ProtocolConstant30_UIHV.MSG_CONFIG_ACK)) { + return new DAResult(ErrorCode.SUCCESS); + } else { + return new DAResult(ErrorCode.ERR_CONFIG_FAILED); + } + } + + @Override + public DAResult sendUIHierarchyMessage(IProgress progress, int requestOption) + throws InterruptedException, UnsupportedProtocolException { + ProtocolSerializer ps = new ProtocolSerializer(); + ps.setMessageID(ProtocolConstant30_UIHV.MSG_GET_UI_HIERARCHY); + ps.putByte((byte)requestOption); + byte[] msg = ps.toByteArray(); + + AckMessage ack = parent.handleControlMessage(msg, 0); + if (ack == null || !ack.isCorrectID(ProtocolConstant30_UIHV.MSG_GET_UI_HIERARCHY_ACK)) { + return new DAResult(ErrorCode.ERR_RECEIVE_ACK_FAIL); + } else if (ack.isSuccess()) { + return DAResult.SUCCESS; + } else { + return new DAResult(ErrorCode.ERR_UIHIERARCHY_GET_FAIL); + } + } + + @Override + public DAResult sendUIScreenshotMessage(IProgress progress, long uiObjectAddress) + throws InterruptedException, UnsupportedProtocolException { + ProtocolSerializer ps = new ProtocolSerializer(); + ps.setMessageID(ProtocolConstant30_UIHV.MSG_GET_UI_SCREENSHOT); + ps.putLong(uiObjectAddress); + byte[] msg = ps.toByteArray(); + + AckMessage ack = parent.handleControlMessage(msg, 0); + if (ack == null || !ack.isCorrectID(ProtocolConstant30_UIHV.MSG_GET_UI_SCREENSHOT_ACK)) { + return new DAResult(ErrorCode.ERR_RECEIVE_ACK_FAIL); + } else if (ack.isSuccess()) { + ProtocolParser parser = new ProtocolParser(ack.getPayload()); + parser.getInt(); // for return code + String from = parser.getString(); + String fileName = Long.toString(uiObjectAddress); + String to = Global.getProject().getSavePath() + File.separator + + AnalyzerConstants.IMAGE_FOLDER_NAME + File.separator + fileName; + if (DownloadContentfileManager.pullFile(from, to) == false) { + return new DAResult(ErrorCode.ERR_DOWNLOAD_FILE_FAILED); + } + } else if (ack.getReturnCode() == SwapErrorCode.ERR_UI_OBJECT_CAN_NOT_TAKE_SCREENSHOT + .getErrorNumber()) { + return new DAResult(ErrorCode.ERR_UI_OBJECT_CAN_NOT_TAKE_SCREENSHOT); + } else if (ack.getReturnCode() == SwapErrorCode.ERR_UI_OBJECT_NOT_FOUND.getErrorNumber()) { + return new DAResult(ErrorCode.ERR_UI_OBJECT_NOT_FOUND); + } + return DAResult.SUCCESS; + } + + @Override + public DAResult sendUIHierarchyCancelMessage(IProgress progress) throws InterruptedException, + UnsupportedProtocolException { + ProtocolSerializer ps = new ProtocolSerializer(); + ps.setMessageID(ProtocolConstant30_UIHV.MSG_GET_UI_HIERARCHY_CANCEL); + byte[] msg = ps.toByteArray(); + + AckMessage ack = parent.handleControlMessage(msg, 0); + if (ack == null || !ack.isCorrectID(ProtocolConstant30_UIHV.MSG_GET_UI_HIERARCHY_CANCEL_ACK)) { + return new DAResult(ErrorCode.ERR_RECEIVE_ACK_FAIL); + } else if (ack.isSuccess()) { + Logger.info("Cancel is successed."); + return DAResult.SUCCESS; + } + Logger.warning("sendUIHierarchyCancelMessage is failed with error (" + ack.getReturnCode() + + ")"); + return new DAResult(ErrorCode.ERR_UIHIERARCHY_GET_CANCEL_FAIL); + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConfig30_UIHV.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConfig30_UIHV.java new file mode 100644 index 0000000..220c5b3 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConfig30_UIHV.java @@ -0,0 +1,179 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2013 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Jaewon Lim + * Woojin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ +package org.tizen.dynamicanalyzer.protocol.p30_uihv; + +import java.util.Collections; +import java.util.EnumMap; +import java.util.Map; +import java.util.Set; + +import org.tizen.dynamicanalyzer.protocol.IProtocolConfig; +import org.tizen.dynamicanalyzer.setting.Feature; +import org.tizen.dynamicanalyzer.util.ByteUtil; + +public enum ProtocolConfig30_UIHV implements IProtocolConfig { + RESERVED1(0, 0, 0, null), + RESERVED2(1, 0, 0, null), + FUNCTION_PROFILING(2, 36, 5000, null), + MEMORY_ALLOC_PROBE(3, 40, 623, null), + FILE_API_PROBE(4, 26, 918, null), + THREAD_API_PROBE(5, 0, 106, null), + OSPUI_API_PROBE(6, 0, 0, null), + SCREENSHOT(7, 62, 10, null), + USER_EVENT(8, 0, 45, null), + RECORDING(9, 996, 17, null), + SYSCALL_FILE(10, 14, 0, null), + SYSCALL_IPC(11, 14, 0, null), + SYSCALL_PROCESS(12, 14, 0, null), + SYSCALL_SIGNAL(13, 14, 0, null), + SYSCALL_NETWORK(14, 14, 0, null), + SYSCALL_DESC(15, 14, 0, null), + CONTEXT_SWITCH(16, 14, 0, null), + NETWORK_API_PROBE(17, 38, 10021, null), + OPENGL_API_PROBE(18, 16, 50000, null), + FUNCTION_SAMPLING(19, 68, 0, Feature.FUNCTION_SAMPLING_RATE), + + INTERNAL_MEMORY_ALLOC(28, 40, 0, null), + INTERNAL_FILE_API(29, 26, 0, null), + INTERNAL_THREAD_API(30, 0, 0, null), + INTERNAL_OSPUI_API(31, 0, 0, null), + INTERNAL_NETWORK_API(32, 38, 0, null), + INTERNAL_OPENGL_API(33, 16, 0, null), + + SYSTEM_CPU(36, 2438, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_MEMORY(37, 2282, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_PROCESS(38, 2568, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_THREAD_LOAD(39, 2344, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_PROCESSES_LOAD(40, 2504, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_DISK(41, 1222, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_NETWORK(42, 162, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_DEVICE(43, 756, 0, Feature.SYSTEM_SAMPLING_RATE), + SYSTEM_ENERGY(44, 452, 0, Feature.SYSTEM_SAMPLING_RATE), + + // added for UI Hierarchy analysis + UI_HIERARCHY(49, 0, 45, null); + + private static final Map featureProtocolMap; + + static { + Map tempMap = new EnumMap( + Feature.class); + tempMap.put(Feature.SYSTEM_CPU, new ProtocolConfig30_UIHV[] { SYSTEM_CPU }); + tempMap.put(Feature.SYSTEM_PROCESS, new ProtocolConfig30_UIHV[] { SYSTEM_PROCESS }); + tempMap.put(Feature.SYSTEM_MEMORY, new ProtocolConfig30_UIHV[] { SYSTEM_MEMORY }); + tempMap.put(Feature.SYSTEM_ALL_PROCESSES, new ProtocolConfig30_UIHV[] { SYSTEM_PROCESSES_LOAD }); + tempMap.put(Feature.SYSTEM_DISK, new ProtocolConfig30_UIHV[] { SYSTEM_DISK }); + tempMap.put(Feature.SYSTEM_NETWORK, new ProtocolConfig30_UIHV[] { SYSTEM_NETWORK }); + tempMap.put(Feature.SYSTEM_DEVICE, new ProtocolConfig30_UIHV[] { SYSTEM_DEVICE }); + tempMap.put(Feature.SYSTEM_ENERGY, new ProtocolConfig30_UIHV[] { SYSTEM_ENERGY }); + tempMap.put(Feature.FUNCTION_PROFILING, new ProtocolConfig30_UIHV[] { FUNCTION_PROFILING }); + tempMap.put(Feature.FUNCTION_SAMPLING, new ProtocolConfig30_UIHV[] { FUNCTION_SAMPLING }); + tempMap.put(Feature.MEMORY_ALLOCATION, new ProtocolConfig30_UIHV[] { MEMORY_ALLOC_PROBE }); + tempMap.put(Feature.FILE_ANALYSIS, new ProtocolConfig30_UIHV[] { FILE_API_PROBE, SYSCALL_FILE }); + tempMap.put(Feature.THREAD_ANALYSIS, new ProtocolConfig30_UIHV[] { THREAD_API_PROBE, + SYSTEM_THREAD_LOAD }); + tempMap.put(Feature.NETWORK_ANALYSIS, new ProtocolConfig30_UIHV[] { NETWORK_API_PROBE }); + tempMap.put(Feature.OPENGL_ANALYSIS, new ProtocolConfig30_UIHV[] { OPENGL_API_PROBE }); + tempMap.put(Feature.UI_EVENT_ANALYSIS, new ProtocolConfig30_UIHV[] { USER_EVENT }); + tempMap.put(Feature.CONTEXT_SWITCH_ANALYSIS, new ProtocolConfig30_UIHV[] { CONTEXT_SWITCH }); + tempMap.put(Feature.INTERNAL_PROBE_MEMORY, new ProtocolConfig30_UIHV[] { INTERNAL_MEMORY_ALLOC }); + tempMap.put(Feature.INTERNAL_PROBE_FILE, new ProtocolConfig30_UIHV[] { INTERNAL_FILE_API }); + tempMap.put(Feature.INTERNAL_PROBE_THREAD, new ProtocolConfig30_UIHV[] { INTERNAL_THREAD_API }); + tempMap.put(Feature.INTERNAL_PROBE_NETWORK, new ProtocolConfig30_UIHV[] { INTERNAL_NETWORK_API }); + tempMap.put(Feature.INTERNAL_PROBE_OPENGL, new ProtocolConfig30_UIHV[] { INTERNAL_OPENGL_API }); + tempMap.put(Feature.SYSCALL_FILE, new ProtocolConfig30_UIHV[] { SYSCALL_FILE }); + tempMap.put(Feature.SYSCALL_IPC, new ProtocolConfig30_UIHV[] { SYSCALL_IPC }); + tempMap.put(Feature.SYSCALL_PROCESS, new ProtocolConfig30_UIHV[] { SYSCALL_PROCESS }); + tempMap.put(Feature.SYSCALL_SIGNAL, new ProtocolConfig30_UIHV[] { SYSCALL_SIGNAL }); + tempMap.put(Feature.SYSCALL_NETWORK, new ProtocolConfig30_UIHV[] { SYSCALL_NETWORK }); + tempMap.put(Feature.SYSCALL_DESC, new ProtocolConfig30_UIHV[] { SYSCALL_DESC }); + tempMap.put(Feature.SCREENSHOT_ON_SCENE_TRANSITION, new ProtocolConfig30_UIHV[] { SCREENSHOT }); + tempMap.put(Feature.RECORDING, new ProtocolConfig30_UIHV[] { RECORDING }); + tempMap.put(Feature.UI_HIERARCHY_ANALYSIS, new ProtocolConfig30_UIHV[] { UI_HIERARCHY }); + featureProtocolMap = Collections.unmodifiableMap(tempMap); + } + + private int bitShift; + private int overheadValue; + private int callCount; + private Feature featureForFrequency; + + private ProtocolConfig30_UIHV(int bitshift, int overhead, int callcount, Feature frequency) { + this.bitShift = bitshift; + this.overheadValue = overhead; + this.callCount = callcount; + this.featureForFrequency = frequency; + } + + public int getShift() { + return bitShift; + } + + public int getOverhead() { + return overheadValue; + } + + public int getCallcount() { + return callCount; + } + + public Feature getFeatureForFrequency() { + return featureForFrequency; + } + + public static byte[] getFeatureFlagValue(Set features) { + long lowValue = 0; + long highValue = 0; + if (features != null) { + for (Feature feature : features) { + IProtocolConfig[] configs = featureProtocolMap.get(feature); + if (configs != null) { + for (int i = 0; i < configs.length; i++) { + int bitshift = configs[i].getShift(); + if (bitshift >= 64) { // high 8byte bit + highValue |= (0x1L << (bitshift - 64)); + } else { // low 8byte bit + lowValue |= (0x1L << bitshift); + } + } + } + } + } + + byte[] lowbyte = ByteUtil.toBytes(lowValue); + byte[] highbyte = ByteUtil.toBytes(highValue); + byte[] ret = new byte[16]; + + System.arraycopy(lowbyte, 0, ret, 0, 8); + System.arraycopy(highbyte, 0, ret, 8, 8); + + return ret; + } + + public static IProtocolConfig[] getProtocolConfig(Feature feature) { + return featureProtocolMap.get(feature); + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConstant30_UIHV.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConstant30_UIHV.java new file mode 100644 index 0000000..f261576 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/protocol/p30_uihv/ProtocolConstant30_UIHV.java @@ -0,0 +1,54 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2013 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Jaewon Lim + * Woojin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ +package org.tizen.dynamicanalyzer.protocol.p30_uihv; + +import org.tizen.dynamicanalyzer.protocol.p30.ProtocolConstant30; + +public class ProtocolConstant30_UIHV extends ProtocolConstant30 { + // changed from protocol 3.0 + public static final int MSG_KEEP_ALIVE = 0x000F; + // added in protocol 3.0_UIHV + public static final int MSG_VERSION = 0x0001; + + // changed from protocol 3.0 + public static final int MSG_VERSION_ACK = 0x1001; + public static final int MSG_KEEP_ALIVE_ACK = 0x100F; + + // added for UI Hierarchy + public static final int MSG_GET_UI_HIERARCHY = 0x0012; + public static final int MSG_GET_UI_SCREENSHOT = 0x0013; + public static final int MSG_GET_UI_HIERARCHY_CANCEL = 0x0014; + public static final int MSG_GET_UI_HIERARCHY_ACK = 0x1012; + public static final int MSG_GET_UI_SCREENSHOT_ACK = 0x1013; + public static final int MSG_GET_UI_HIERARCHY_CANCEL_ACK = 0x1014; + /* + * Options of MSG_GET_UI_HIERARCHY + */ + public final static int REQEUST_OPTION_ALL = 0; + public final static int REQUEST_OPTION_ALL_WITH_RENDER = 1; + public final static int REQUEOST_OPTION_ELEMENTARY_WITH_RENDER = 2; + public final static int REQUEST_OPTION_ELEMENTARY = 3; +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/FeatureData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/FeatureData.java index 1e1d9ee..da0ddc8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/FeatureData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/FeatureData.java @@ -40,8 +40,8 @@ public class FeatureData { private int featureType = SettingConstants.FEATURE_TYPE_MAIN; private int parentIndex = 0; private String description = null; - private List pageList = null; - private List chartList = null; + private List pageList = new ArrayList(); + private List chartList = new ArrayList(); private int minValue = 0; private int maxValue = 0; @@ -129,51 +129,41 @@ public class FeatureData { } public List getPageList() { - if (pageList == null) { - pageList = new ArrayList(); - } return pageList; } public List getChartList() { - if (chartList == null) { - chartList = new ArrayList(); - } return chartList; } /** - * When choosing a feature, which generates a list of pages.
+ * When choosing a feature, which generates a list of pages. * (example Timeline, File, Thread, etc) * - * @param data - * Page Information + * @param data Page Information */ public void makePageList(String data) { // format : "tabPage-tabPage-..." - List pages = getPageList(); if (data != null && !data.isEmpty()) { String list[] = data.split(CommonConstants.DASH); for (int i = 0; i < list.length; i++) { - pages.add(list[i]); + pageList.add(list[i]); } } // else : do nothing } /** - * When choosing a feature, which generates a list of charts.
+ * When choosing a feature, which generates a list of charts. * (example CPU, Disk IO, Energy, etc) * - * @param data - * Chart Information + * @param data Chart Information */ public void makeChartList(String data) { // format : "chart-chart-..." - List charts = getChartList(); if (data != null && !data.isEmpty()) { String list[] = data.split(CommonConstants.DASH); for (int i = 0; i < list.length; i++) { - charts.add(list[i]); + chartList.add(list[i]); } } // else : do nothing } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingConstants.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingConstants.java index 9971064..94eda6b 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingConstants.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingConstants.java @@ -76,13 +76,6 @@ public class SettingConstants { public static final int FEATURE_TYPE_SUB = 1; public static final int FEATURE_TYPE_DETAIL = 2; - // input text error code - public static final int FEATURE_VAILD_VALUE = 0; - public static final int FEATURE_INVAILD_VALUE_EMPTY = -1; - public static final int FEATURE_INVAILD_VALUE_CHARACTER = -2; - public static final int FEATURE_INVAILD_VALUE_RANGE = -3; - public static final int FEATURE_INVALID_VALUE_RISE_RANGE = -4; - public static final String MIN_VALUE = "minValue"; public static final String MAX_VALUE = "maxValue"; @@ -91,6 +84,9 @@ public class SettingConstants { public static final int FEATURE_OVERHEAD_RANKING_MIDDLE = 2; public static final int FEATURE_OVERHEAD_RANKING_HIGH = 3; + // overhead and call count measuring time = 30 sec + public static final int OVERHEAD_AVG_SECONDS = 30; + /** template **/ // template key index in template file public static final int TEMPLATE_KEY_TEMPLATE_INDEX = 0; @@ -101,19 +97,6 @@ public class SettingConstants { public static final String KEY_DEFAULT_CHART_LIST = "Default Chart List"; public static final String KEY_SELECTED_CHART_LIST = "Selected Chart List"; - /** protocol **/ - // protocol key index in protocol file - public static final int PROTOCOL_KEY_PROTOCOL_INDEX = 0; - public static final int PROTOCOL_KEY_PROTOCOL_NAME = 1; - public static final int PROTOCOL_KEY_SWAP_LOW_VALUE = 2; - public static final int PROTOCOL_KEY_SWAP_HIGH_VALUE = 3; - public static final int PROTOCOL_KEY_OVERHEAD_VALUE = 4; - public static final int PROTOCOL_KEY_OVERHEAD_AVG_CALL_COUNT = 5; - public static final int PROTOCOL_KEY_OVERHEAD_FEATURE_INDEX = 6; - - // overhead and call count measuring time = 30 sec - public static final int OVERHEAD_AVG_SECONDS = 30; - /** about UI **/ // page names public static String PAGE_NAME_TIME_LINE = "Timeline"; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingDataManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingDataManager.java index 6608b17..cb0cc83 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingDataManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/SettingDataManager.java @@ -357,7 +357,6 @@ public enum SettingDataManager { } /****************************** protocol operation ******************************/ - public int getSelectedOverheadLevel(String targetName) { int totalRange = 0; long calculateValue = 0; @@ -449,7 +448,6 @@ public enum SettingDataManager { } /********************************** chart set manipulation ***************************/ - public Set getOptionsSelectedFeatureChartSet() { Set selectedChartSet = new HashSet(); for (int i = 0; i < optionsSelectedFeatureList.size(); i++) { @@ -464,8 +462,7 @@ public enum SettingDataManager { /** * Get chart information shown on the screen. * - * @param targetName - * targetName + * @param targetName targetName * * @return The chart name list to be shown on the screen. */ @@ -487,19 +484,7 @@ public enum SettingDataManager { } } - /** - * Update selected chart set by current setting - */ - public void updateChartSet() { - /*- - * selected chart set = union of (default chart set, chart set of selected feature, - * chart set of option selected) - */ - - } - /*********************************** Target manipulation ******************************/ - public String getSelectedTarget() { return selectedTarget; } @@ -540,7 +525,6 @@ public enum SettingDataManager { } /********************************** Feature manipulation ******************************/ - public List getDefaultFeatureList() { return Collections.unmodifiableList(defaultFeatureList); } @@ -625,7 +609,6 @@ public enum SettingDataManager { } /******************************* Overhead manipulation *********************************/ - public List getTotalOverheadRange() { return Collections.unmodifiableList(totalOverheadRange); } @@ -635,13 +618,10 @@ public enum SettingDataManager { } /******************************* Page list manipulation ********************************/ - /** * Get page information shown on the screen. * - * @param targetName - * targetName - * + * @param targetName targetName * @return The page name list to be shown on the screen. */ public Set getSelectedPageList(String targetName) { @@ -657,12 +637,10 @@ public enum SettingDataManager { } else { Logger.debug("Does not exist targetName : " + targetName); } - return selectedPageList; } /******************************* miscellaneous **********************************/ - private void copyFeatureList(List source, List dest) { dest.clear(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TargetData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TargetData.java index be1a594..24512fa 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TargetData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TargetData.java @@ -47,7 +47,7 @@ public class TargetData { /** write information **/ // init selected information : for revert button private Template initTemplate = null; - private List initFeatureList = null; + private List initFeatureList = new ArrayList(); // dialog selected information private Template selectedTemplate = null; @@ -129,8 +129,7 @@ public class TargetData { /** * Change the selected feature list. * - * @param template - * selected template + * @param template selected template */ public void changeSelectedFeatureList(Template template) { if (template.equals(selectedTemplate)) { @@ -144,9 +143,7 @@ public class TargetData { /** * Get the value of the selected feature. * - * @param feature - * one of the selected features - * + * @param feature one of the selected features * @return featureValue (If the feature is not selected, returns -1.) */ public int getSelectedFeatureValue(Feature feature) { @@ -205,12 +202,8 @@ public class TargetData { selectedFeatureList.add(feature); } - // init Feature list - if (initFeatureList == null) { - initFeatureList = new ArrayList(); - copyFeatureList(selectedFeatureList, initFeatureList); - } + copyFeatureList(selectedFeatureList, initFeatureList); } private void makeAvailableChartList(String list[]) { @@ -224,9 +217,7 @@ public class TargetData { /** * Write the selected template/feature information in the setting file. * - * @param writer - * setting file Writer - * + * @param writer setting file Writer * @throws IOException */ public void writeSelectedData(PrintWriter writer) throws IOException { @@ -271,7 +262,6 @@ public class TargetData { private String writeAvailableChartListData() { StringBuffer buffer = new StringBuffer(); - for (int i = 0; i < availableChartList.size(); i++) { if (i < availableChartList.size() - 1) { buffer.append(availableChartList.get(i) + SettingConstants.WRITE_CSV_SEPARATOR); @@ -284,7 +274,6 @@ public class TargetData { private String writeAvailableTemplateListData() { StringBuffer buffer = new StringBuffer(); - for (int i = 0; i < availableTemplateList.size(); i++) { if (i < availableTemplateList.size() - 1) { buffer.append(availableTemplateList.get(i).getIndex() @@ -298,7 +287,6 @@ public class TargetData { private String writeAvailableFeatureListData() { StringBuffer buffer = new StringBuffer(); - for (int i = 0; i < availableFeatureList.size(); i++) { if (i < availableFeatureList.size() - 1) { buffer.append(availableFeatureList.get(i).getIndex() diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/Template.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/Template.java index 99b4e25..d94ac4d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/Template.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/Template.java @@ -49,7 +49,9 @@ public enum Template { ConfigureLabels.TEMPLATE_DESCRIPTION_OPEN_GL), TEMPLATE_ENERGY(9, ConfigureLabels.TEMPLATE_NAME_ENERGY, ConfigureLabels.TEMPLATE_DESCRIPTION_ENERGY), - TEMPLATE_CUSTOM(10, ConfigureLabels.TEMPLATE_NAME_CUSTOM, + TEMPLATE_UI_HIERARCHY(10, ConfigureLabels.TEMPLATE_NAME_UI_HIERARCHY, + ConfigureLabels.TEMPLATE_DESCRIPTION_UI_HIERARCHY), + TEMPLATE_CUSTOM(11, ConfigureLabels.TEMPLATE_NAME_CUSTOM, ConfigureLabels.TEMPLATE_DESCRIPTION_CUSTOM); private static final Map templateByIndex = new HashMap(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TemplateData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TemplateData.java index 158536c..4f2fb1f 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TemplateData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/TemplateData.java @@ -32,7 +32,7 @@ import org.tizen.dynamicanalyzer.constant.CommonConstants; public class TemplateData { private Template key; - private List featureList = null; + private List featureList = new ArrayList(); public TemplateData(Template template) { this.key = template; @@ -51,37 +51,31 @@ public class TemplateData { } public List getFeatureList() { - if (featureList == null) { - featureList = new ArrayList(); - } return featureList; } /** * Generates a list of features included in the template. * - * @param data - * Feature information + * @param data Feature information */ public void makeFeatureList(String data) { if (data != null) { - List features = getFeatureList(); - // format : "featureIndex:featureValue" String valueList[] = data.split(CommonConstants.COLON); int index = Integer.parseInt(valueList[0]); // set featureIndex FeatureValueData feature = null; - for (int i = 0; i < features.size(); i++) { - if (features.get(i).getKey().getIndex() == index) { - feature = features.get(i); + for (int i = 0; i < featureList.size(); i++) { + if (featureList.get(i).getKey().getIndex() == index) { + feature = featureList.get(i); } // else : do nothing } if (feature == null) { feature = new FeatureValueData(Feature.getFeature(index)); - features.add(feature); + featureList.add(feature); } // set featureValue diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/UILayoutDataManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/UILayoutDataManager.java index bacd3bf..002326f 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/UILayoutDataManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/setting/UILayoutDataManager.java @@ -46,13 +46,12 @@ import org.tizen.dynamicanalyzer.util.Logger; public enum UILayoutDataManager { INSTANCE; + // isDirty is used to update (page and chart) to start after open private boolean isDirty = false; private Set defaultChartSet = new HashSet(); private Set selectedChartSet = new HashSet(); - private Set selectedPageSet = new HashSet(); - private UILayoutDataManager() { // set SettingFilePath if (null == SettingConstants.SettingFilePath) { @@ -131,7 +130,6 @@ public enum UILayoutDataManager { } /** getter and setter **/ - public boolean isDirty() { return isDirty; } @@ -160,13 +158,4 @@ public enum UILayoutDataManager { writeLayoutFile(); return ret; } - - public Set getSelectedPageSet() { - return Collections.unmodifiableSet(selectedPageSet); - } - - public void setSelectedPageSet(Collection selectedPageList) { - this.selectedPageSet.clear(); - this.selectedPageSet.addAll(selectedPageList); - } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/communicator/DataChannelThread.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/communicator/DataChannelThread.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/LogPackage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/LogPackage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/LogParser.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/LogParser.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/Logs.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/Logs.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/MessageParser.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/MessageParser.java old mode 100755 new mode 100644 index a34a699..2689212 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/MessageParser.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/logparser/MessageParser.java @@ -288,7 +288,9 @@ public class MessageParser extends DataThread { BinaryInfo bininfo = project.getDeviceStatusInfo().getBinaryInfo(libPath); LibraryObject libObj = new LibraryObject(bininfo.getID(), lowAddr, highAddr); if (!lastMap.addLibraryMap(libObj)) { - Logger.error("exist library"); + Logger.error("exist library(%d, %d, %s)", lowAddr, highAddr, libPath); + } else { + Logger.debug("map library(%d, %d, %s)", lowAddr, highAddr, libPath); } pinfo.setMappingState(true); @@ -309,6 +311,8 @@ public class MessageParser extends DataThread { lastMap.removeLibrary(lowAddr, highAddr); } + Logger.debug("unmap library(%d, %d)", lowAddr, highAddr); + pinfo.setMappingState(false); } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/FunctionBodyInstrumentData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/FunctionBodyInstrumentData.java index 8d1e59a..dbe534d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/FunctionBodyInstrumentData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/FunctionBodyInstrumentData.java @@ -62,7 +62,8 @@ public class FunctionBodyInstrumentData extends LogData { } public UnsignedInt getVariableID() throws UnsupportedProtocolException { - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { throw new UnsupportedProtocolException(); } return variableID; @@ -73,7 +74,8 @@ public class FunctionBodyInstrumentData extends LogData { } public UnsignedInt getSize() throws UnsupportedProtocolException { - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { throw new UnsupportedProtocolException(); } return size; @@ -84,7 +86,8 @@ public class FunctionBodyInstrumentData extends LogData { } public byte[] getData() throws UnsupportedProtocolException { - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { throw new UnsupportedProtocolException(); } return data; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogData.java index 0253736..e6669d2 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogData.java @@ -88,9 +88,11 @@ public class LogData extends ProtocolParser implements Cloneable { protected boolean parse(DATime startTime) { // print message header - DebugLog.printData0("%s seq(%d) sec(%d) nano(%d) size(%d)\n", - Protocol.getDataMessageName(getMsgID()), getSeq(), getSec(), getNano(), - getPayloadSize()); + if (DebugLog.isEnabled()) { + DebugLog.printData0("%s seq(%d) sec(%d) nano(%d) size(%d)\n", + Protocol.getDataMessageName(getMsgID()), getSeq(), getSec(), getNano(), + getPayloadSize()); + } return true; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogDataTimeComparator.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/LogDataTimeComparator.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/MemoryMapData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/MemoryMapData.java index c72ff52..ca4ede1 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/MemoryMapData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/MemoryMapData.java @@ -52,14 +52,21 @@ public class MemoryMapData extends LogData { lowAddr = getLong(); highAddr = getLong(); - DebugLog.printData1("pid(%d) lowAddr(%x) highAddr(%x) ", pid, lowAddr, highAddr); + if (DebugLog.isEnabled()) { + DebugLog.printData1("pid(%d) lowAddr(%x) highAddr(%x) ", pid, lowAddr, highAddr); + } int msgid = getMsgID(); if (msgid == ProtocolConstants.MSG_PROCESS_MAP) { libPath = getString(); - DebugLog.printData0("libPath(%s)", libPath); + if (DebugLog.isEnabled()) { + DebugLog.printData0("libPath(%s)", libPath); + } + } + + if (DebugLog.isEnabled()) { + DebugLog.printData0("\n"); } - DebugLog.printData0("\n"); // end of protocol 3.0 return true; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessAddInfoData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessAddInfoData.java index c36485b..993b88a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessAddInfoData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessAddInfoData.java @@ -48,7 +48,9 @@ public class ProcessAddInfoData extends LogData { pid = getInt(); cmdname = getString(); - DebugLog.printData1("pid(%d) process(%s)\n", pid, cmdname); + if (DebugLog.isEnabled()) { + DebugLog.printData1("pid(%d) process(%s)\n", pid, cmdname); + } // end of protocol 3.0 return true; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessInfoData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessInfoData.java index 9513b9d..a49334b 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessInfoData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProcessInfoData.java @@ -68,18 +68,22 @@ public class ProcessInfoData extends LogData { binaryPath = getString(); int dependentLibCount = getInt(); - DebugLog.printData1("pid(%d) cmd(%s) ppid(%d) sec(%d) nano(%d) ", pid, cmdname, ppid, - second, nanosecond); - DebugLog.printData0("lowAddr(%x) highAddr(%x) path(%s) libcount(%d)\n", lowAddr, highAddr, - binaryPath, dependentLibCount); + if (DebugLog.isEnabled()) { + DebugLog.printData1("pid(%d) cmd(%s) ppid(%d) sec(%d) nano(%d) ", pid, cmdname, ppid, + second, nanosecond); + DebugLog.printData0("lowAddr(%x) highAddr(%x) path(%s) libcount(%d)\n", lowAddr, + highAddr, binaryPath, dependentLibCount); + } for (int i = 0; i < dependentLibCount; i++) { long lowestAddr = getLong(); long highestAddr = getLong(); String libPath = getString(); - DebugLog.printData2("lowAddr(%x) highAddr(%x) libPath(%s)\n", lowestAddr, highestAddr, - libPath); + if (DebugLog.isEnabled()) { + DebugLog.printData2("lowAddr(%x) highAddr(%x) libPath(%s)\n", lowestAddr, + highestAddr, libPath); + } LibraryObject libObj = new LibraryObject(Global.getProject().getDeviceStatusInfo() .getBinaryInfo(libPath).getID(), lowestAddr, highestAddr); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProfileData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProfileData.java index 810ae50..604daff 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProfileData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/ProfileData.java @@ -114,7 +114,8 @@ public class ProfileData extends LogData { tid = getInt(); // removed from protocol 4.0 and later - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { probeType = getShort(); probeSubType = getShort(); } @@ -131,7 +132,8 @@ public class ProfileData extends LogData { tid = getInt(); // removed from protocol 4.0 and later - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { probeType = getShort(); probeSubType = getShort(); } @@ -152,11 +154,12 @@ public class ProfileData extends LogData { break; } - if (protocolVersion != Protocol.VERSION_30 + if ((protocolVersion != Protocol.VERSION_30 && protocolVersion != Protocol.VERSION_30A && protocolVersion != Protocol.VERSION_30_UIHV) || probeType != ProtocolConstants.FUNCTION_TYPE_FILE) { binaryId = Global.getBinaryID(pid, time, pcAddr); if (binaryId == AnalyzerConstants.INVALID_ID) { - Logger.error("ProfileData of type: " + msgID + " is from wrong process: " + pid); + Logger.error("ProfileData of %s is from wrong process(%d) or wrong address(%d)", + Protocol.getDataMessageName(msgID), pid, pcAddr); return false; } } @@ -182,7 +185,8 @@ public class ProfileData extends LogData { } public int getProbeType() throws UnsupportedProtocolException { - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { return probeType; } else { throw new UnsupportedProtocolException(); @@ -194,7 +198,8 @@ public class ProfileData extends LogData { } public int getProbeSubType() throws UnsupportedProtocolException { - if (protocolVersion == Protocol.VERSION_30) { + if (protocolVersion == Protocol.VERSION_30 || protocolVersion == Protocol.VERSION_30A + || protocolVersion == Protocol.VERSION_30_UIHV) { return probeSubType; } else { throw new UnsupportedProtocolException(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/SystemData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/SystemData.java index a05fbad..91d6df8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/SystemData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/SystemData.java @@ -26,9 +26,12 @@ */ package org.tizen.dynamicanalyzer.swap.model.data; +import java.util.Arrays; + import org.tizen.dynamicanalyzer.common.Global; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.model.DATime; +import org.tizen.dynamicanalyzer.protocol.DebugLog; import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.dynamicanalyzer.util.UnsignedInt; @@ -99,6 +102,13 @@ public class SystemData extends LogData { systemMemoryUsed = getLong(); targetProcessCount = getInt(); + // print log for debugging + if (DebugLog.isEnabled()) { + DebugLog.printData1("CpuFreq(%s), CpuLoad(%s), sysMemUsed(%d), ProcCount(%d)\n", + Arrays.toString(cpuFrequency), Arrays.toString(cpuLoad), systemMemoryUsed, + targetProcessCount); + } + parseTargetProcessInfo(targetProcessCount); otherProcessCount = getInt(); @@ -131,6 +141,20 @@ public class SystemData extends LogData { applicationEnergyUsage = parseUsage(); // end of protocol 3.0 + // print log for debugging + if (DebugLog.isEnabled()) { + DebugLog.printData1("OtherProc(%d,%s)\n", otherProcessCount, otherProcessLoad); + DebugLog.printData1("UsedDisk(%s), Read(%s,%s), Write(%s,%s), Send(%s), Recv(%s)\n", + totalUsedDrive, diskReadOpCount, diskReadByteSize, diskWriteOpCount, + diskWrittenByteSize, networkSendSize, networkReceiveSize); + DebugLog.printData1("WF(%d), BT(%d), GPS(%d), BR(%d), CMR(%d), SND(%d), AD(%d)\n", + wifi, btStatus, gpsStatus, brightness, camera, sound, audio); + DebugLog.printData1("VBR(%d), VT(%d), RSSI(%d), VD(%d), CALL(%d), DNET(%d), ENG(%s)\n", + vibration, voltage, rssi, video, call, dnet, energyUsage); + DebugLog.printData1("DeviceEnergy(%s), AppEnergy(%s)\n", deviceEnergyUsage, + applicationEnergyUsage); + } + return true; } @@ -194,6 +218,17 @@ public class SystemData extends LogData { processData.setThreadLoad(parseLoad(processData.getThreadCount())); // end of protocol 3.0 processProfileDataList[i] = processData; + + // print log for debugging + if (DebugLog.isEnabled()) { + DebugLog.printData2( + "%d: pid(%d), Load(%f), V.R.S.P.A(%d,%d,%d,%d,%d), Thread(%d,%s)\n", i, + processData.getPid(), processData.getProcessLoad(), + processData.getVirtualMemory(), processData.getResidentMemory(), + processData.getSharedMemory(), processData.getPssMemory(), + processData.getTotalAllocSize(), processData.getThreadCount(), + processData.getThreadLoad()); + } } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/UIHierarchyData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/UIHierarchyData.java index a32dc6e..8250deb 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/UIHierarchyData.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/UIHierarchyData.java @@ -38,7 +38,6 @@ import org.tizen.dynamicanalyzer.common.Global; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; import org.tizen.dynamicanalyzer.communicator.UnsupportedProtocolException; import org.tizen.dynamicanalyzer.model.DATime; -import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.protocol.p41.ProtocolConstant41; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObject; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObject.RENDER_SPEED_GRADE; @@ -121,10 +120,14 @@ public class UIHierarchyData extends LogData { } public String getFilePath() throws UnsupportedProtocolException { - if (protocolVersion != Protocol.VERSION_41) { + switch (protocolVersion) { + case VERSION_30: + case VERSION_30A: + case VERSION_40: throw new UnsupportedProtocolException(); + default: + return filePath; } - return filePath; } public void setFilePath(String filePath) { @@ -256,7 +259,7 @@ public class UIHierarchyData extends LogData { private boolean parseProperties(HierarchyUIObject uiObject, ProtocolParser parser) { // Parse Evas properties (Default) - EvasProperties evasProperties = new EvasProperties(); + EvasProperties evasProperties = new EvasProperties(protocolVersion); evasProperties.parsePropertiesFromByte(parser); uiObject.setEvasProperties(evasProperties); @@ -265,12 +268,12 @@ public class UIHierarchyData extends LogData { // Do nothing. Evas is default. break; case ELEMENTARY: - ElementaryProperties elementaryProperties = new ElementaryProperties(); + ElementaryProperties elementaryProperties = new ElementaryProperties(protocolVersion); elementaryProperties.parsePropertiesFromByte(parser); uiObject.setElementaryProperties(elementaryProperties); break; case EDJE: - EdjeProperties edjeProperties = new EdjeProperties(); + EdjeProperties edjeProperties = new EdjeProperties(protocolVersion); edjeProperties.parsePropertiesFromByte(parser); uiObject.setEdjeProperties(edjeProperties); break; @@ -299,94 +302,94 @@ public class UIHierarchyData extends LogData { * Evas */ case 0x0101: // image - return new EvasImageProperties(); + return new EvasImageProperties(protocolVersion); case 0x0102: // line - return new EvasLineProperties(); + return new EvasLineProperties(protocolVersion); case 0x0103: // polygon return null; case 0x0104: // rectangle return null; case 0x0105: // text - return new EvasTextProperties(); + return new EvasTextProperties(protocolVersion); case 0x0106: // textblock - return new EvasTextblockProperties(); + return new EvasTextblockProperties(protocolVersion); case 0x0107: // vector return null; case 0x0108: // table - return new EvasTableProperties(); + return new EvasTableProperties(protocolVersion); case 0x0109: // box - return new EvasBoxProperties(); + return new EvasBoxProperties(protocolVersion); case 0x010A: // grid - return new EvasGridProperties(); + return new EvasGridProperties(protocolVersion); case 0x010B: // textgrid - return new EvasTextgridProperties(); + return new EvasTextgridProperties(protocolVersion); case 0x010C: // smart return null; /* * Elementary */ case 0x0201: // background - return new ElmBackgroundProperties(); + return new ElmBackgroundProperties(protocolVersion); case 0x0202: // button - return new ElmButtonProperties(); + return new ElmButtonProperties(protocolVersion); case 0X0203: // check - return new ElmCheckProperties(); + return new ElmCheckProperties(protocolVersion); case 0X0204: // colorselector - return new ElmColorselectorProperties(); + return new ElmColorselectorProperties(protocolVersion); case 0X0205: // ctxpopup - return new ElmCtxpopupProperties(); + return new ElmCtxpopupProperties(protocolVersion); case 0X0206: // datetime - return new ElmDatetimeProperties(); + return new ElmDatetimeProperties(protocolVersion); case 0X0207: // entry - return new ElmEntryProperties(); + return new ElmEntryProperties(protocolVersion); case 0X0208: // flip - return new ElmFlipProperties(); + return new ElmFlipProperties(protocolVersion); case 0X0209: // gengrid - return new ElmGengridProperties(); + return new ElmGengridProperties(protocolVersion); case 0x020A: // genlist - return new ElmGenlistProperties(); + return new ElmGenlistProperties(protocolVersion); case 0x020B: // glview - return new ElmGlviewProperties(); + return new ElmGlviewProperties(protocolVersion); case 0x020C: // icon - return new ElmIconProperties(); + return new ElmIconProperties(protocolVersion); case 0x020D: // image - return new ElmImageProperties(); + return new ElmImageProperties(protocolVersion); case 0x020E: // index - return new ElmIndexProperties(); + return new ElmIndexProperties(protocolVersion); case 0x020F: // label - return new ElmLabelProperties(); + return new ElmLabelProperties(protocolVersion); case 0x0210: // list - return new ElmListProperties(); + return new ElmListProperties(protocolVersion); case 0x0211: // map - return new ElmMapProperties(); + return new ElmMapProperties(protocolVersion); case 0x0212: // notify - return new ElmNotifyProperties(); + return new ElmNotifyProperties(protocolVersion); case 0x0213: // panel - return new ElmPanelProperties(); + return new ElmPanelProperties(protocolVersion); case 0x0214: // photo - return new ElmPhotoProperties(); + return new ElmPhotoProperties(protocolVersion); case 0x0215: // photocam - return new ElmPhotocamProperties(); + return new ElmPhotocamProperties(protocolVersion); case 0x0216: // plug return null; case 0x0217: // popup - return new ElmPopupProperties(); + return new ElmPopupProperties(protocolVersion); case 0x0218: // progressbar - return new ElmProgressbarProperties(); + return new ElmProgressbarProperties(protocolVersion); case 0x0219: // radio - return new ElmRadioProperties(); + return new ElmRadioProperties(protocolVersion); case 0x021A: // segmentcontrol - return new ElmSegmentcontrolProperties(); + return new ElmSegmentcontrolProperties(protocolVersion); case 0x021B: // slider - return new ElmSliderProperties(); + return new ElmSliderProperties(protocolVersion); case 0x021C: // spinner - return new ElmSpinnerProperties(); + return new ElmSpinnerProperties(protocolVersion); case 0x021D: // toolbar - return new ElmToolbarProperties(); + return new ElmToolbarProperties(protocolVersion); case 0x021E: // tooltip - return new ElmTooltipProperties(); + return new ElmTooltipProperties(protocolVersion); case 0x021F: // win - return new ElmWinProperties(); + return new ElmWinProperties(protocolVersion); default: Logger.warning("Unsupported Object : " + typeCode); return null; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/HierarchyUIObjectProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/HierarchyUIObjectProperties.java index f278ccd..7aa634a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/HierarchyUIObjectProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/HierarchyUIObjectProperties.java @@ -29,12 +29,19 @@ package org.tizen.dynamicanalyzer.swap.model.data.hierarchy; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; public abstract class HierarchyUIObjectProperties { + protected Protocol protocolVersion; + public abstract void parsePropertiesFromByte(ProtocolParser parser); public abstract List getProperties(); // For Properties View + public HierarchyUIObjectProperties(Protocol protocolVersion) { + this.protocolVersion = protocolVersion; + } + /* * Return value is used by search module. If UI object support text property, Implement this * method. diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/edje/EdjeProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/edje/EdjeProperties.java index ab4814a..65c2d16 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/edje/EdjeProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/edje/EdjeProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -41,6 +42,10 @@ public class EdjeProperties extends HierarchyUIObjectProperties { private int[] sizeMin = new int[2]; // w, h private int[] sizeMax = new int[2]; // w, h + public EdjeProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.animation = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElementaryProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElementaryProperties.java index 01313a3..861b5b6 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElementaryProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElementaryProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -39,6 +40,10 @@ public class ElementaryProperties extends HierarchyUIObjectProperties { private boolean disabled; private String widgetType; + public ElementaryProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.text = parser.getString(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmBackgroundProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmBackgroundProperties.java index ca3a231..1ef4755 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmBackgroundProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmBackgroundProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -38,6 +39,10 @@ public class ElmBackgroundProperties extends HierarchyUIObjectProperties { private int[] color = new int[3]; // Red, Green, Blue private String option; + public ElmBackgroundProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.color[0] = parser.getInt(); // r diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmButtonProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmButtonProperties.java index bc61483..a0498fa 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmButtonProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmButtonProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -38,6 +39,10 @@ public class ElmButtonProperties extends HierarchyUIObjectProperties { private double autorepeatGapTimeout; private boolean autorepeat; + public ElmButtonProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.autorepeatInitialTimeout = parser.getFloat(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCheckProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCheckProperties.java index e340048..7c43fad 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCheckProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCheckProperties.java @@ -24,19 +24,23 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; public class ElmCheckProperties extends HierarchyUIObjectProperties { private String state; + public ElmCheckProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.state = getStateMessage(parser.getBoolean()); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmColorselectorProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmColorselectorProperties.java index 2313a43..aecc4d3 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmColorselectorProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmColorselectorProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -40,6 +40,10 @@ public class ElmColorselectorProperties extends HierarchyUIObjectProperties { private String paletteName; private String mode; + public ElmColorselectorProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.color[0] = parser.getInt(); // r diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCtxpopupProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCtxpopupProperties.java index 8d7720f..a12c9ff 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCtxpopupProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmCtxpopupProperties.java @@ -24,19 +24,23 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; public class ElmCtxpopupProperties extends HierarchyUIObjectProperties { private boolean horizontal; + public ElmCtxpopupProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.horizontal = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmDatetimeProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmDatetimeProperties.java index 2d48477..86557e8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmDatetimeProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmDatetimeProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -45,6 +46,10 @@ public class ElmDatetimeProperties extends HierarchyUIObjectProperties { private int wday; /* Day of week. [0-6] */ private int yday; /* Days in year.[0-365] */ + public ElmDatetimeProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.format = parser.getString(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmEntryProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmEntryProperties.java index f112afd..f940ca1 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmEntryProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmEntryProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -53,6 +54,10 @@ public class ElmEntryProperties extends HierarchyUIObjectProperties { private String selection; private boolean cursorIsVisibleFormat; + public ElmEntryProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.entry = parser.getString(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmFlipProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmFlipProperties.java index 4043b91..2ac83ce 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmFlipProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmFlipProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -39,6 +39,10 @@ public class ElmFlipProperties extends HierarchyUIObjectProperties { private String interaction; private boolean frontVisible; + public ElmFlipProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.interaction = getInteractionMessage(parser.getChar()); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGengridProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGengridProperties.java index e997fa2..e37c51c 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGengridProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGengridProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -52,6 +52,10 @@ public class ElmGengridProperties extends HierarchyUIObjectProperties { private boolean wheelDisabled; private int itemCount; + public ElmGengridProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.xAlign = parser.getFloat(); @@ -67,9 +71,13 @@ public class ElmGengridProperties extends HierarchyUIObjectProperties { this.highlightMode = parser.getBoolean(); this.itemSize[0] = parser.getInt(); this.itemSize[1] = parser.getInt(); - this.multiSelectMode = getMultiSelectModeMessage(parser.getChar()); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.multiSelectMode = getMultiSelectModeMessage(parser.getChar()); + } this.horizontal = parser.getBoolean(); - this.wheelDisabled = parser.getBoolean(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.wheelDisabled = parser.getBoolean(); + } this.itemCount = parser.getInt(); } @@ -89,9 +97,14 @@ public class ElmGengridProperties extends HierarchyUIObjectProperties { properties.add(new PropertyValue("highlightMode", Boolean.toString(this.highlightMode))); properties.add(new PropertyValue("itemSize", "[" + this.itemSize[0] + ", " + this.itemSize[1] + "]")); - properties.add(new PropertyValue("multiSelectMode", this.multiSelectMode)); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("multiSelectMode", this.multiSelectMode)); + } properties.add(new PropertyValue("horizontal", Boolean.toString(this.horizontal))); - properties.add(new PropertyValue("wheelDisabled", Boolean.toString(this.wheelDisabled))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties + .add(new PropertyValue("wheelDisabled", Boolean.toString(this.wheelDisabled))); + } properties.add(new PropertyValue("itemCount", Integer.toString(this.itemCount))); return properties; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGenlistProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGenlistProperties.java index f96d454..4e36fb6 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGenlistProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGenlistProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -49,6 +49,10 @@ public class ElmGenlistProperties extends HierarchyUIObjectProperties { private boolean highlightMode; private boolean realizationMode; + public ElmGenlistProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.multiSelect = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGlviewProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGlviewProperties.java index b97c9fc..35c210e 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGlviewProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmGlviewProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -38,18 +38,26 @@ public class ElmGlviewProperties extends HierarchyUIObjectProperties { private int[] size = new int[2]; // width, height private int rotation; + public ElmGlviewProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.size[0] = parser.getInt(); // w this.size[1] = parser.getInt(); // h - this.rotation = parser.getInt(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.rotation = parser.getInt(); + } } @Override public List getProperties() { List properties = new ArrayList(); properties.add(new PropertyValue("size", "[" + this.size[0] + ", " + this.size[1] + "]")); - properties.add(new PropertyValue("rotation", Integer.toString(this.rotation))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("rotation", Integer.toString(this.rotation))); + } return properties; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIconProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIconProperties.java index 4283275..5aa96f8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIconProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIconProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -38,6 +39,10 @@ public class ElmIconProperties extends HierarchyUIObjectProperties { private String orderLookup; private String standard; + public ElmIconProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.orderLookup = getOrderLookupMessage(parser.getChar()); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmImageProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmImageProperties.java index 6f48815..35c9628 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmImageProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmImageProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -49,6 +49,10 @@ public class ElmImageProperties extends HierarchyUIObjectProperties { private boolean animatedAvailable; private int[] size = new int[2]; // w, h + public ElmImageProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.editable = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIndexProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIndexProperties.java index 2324632..26f5702 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIndexProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmIndexProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -43,6 +43,10 @@ public class ElmIndexProperties extends HierarchyUIObjectProperties { private boolean indicatorDisabled; private int itemLevel; + public ElmIndexProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.autohideDisabled = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmLabelProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmLabelProperties.java index 66283b7..e14d2ee 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmLabelProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmLabelProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -40,10 +40,16 @@ public class ElmLabelProperties extends HierarchyUIObjectProperties { private double slideSpeed; private String slideMode; + public ElmLabelProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.wrapWidth = parser.getInt(); - this.slideSpeed = parser.getFloat(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.slideSpeed = parser.getFloat(); + } this.slideMode = getSlideModeMessage(parser.getChar()); } @@ -51,7 +57,9 @@ public class ElmLabelProperties extends HierarchyUIObjectProperties { public List getProperties() { List properties = new ArrayList(); properties.add(new PropertyValue("wrapWidth", Integer.toString(this.wrapWidth))); - properties.add(new PropertyValue("slideSpeed", Double.toString(this.slideSpeed))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("slideSpeed", Double.toString(this.slideSpeed))); + } properties.add(new PropertyValue("slideMode", this.slideMode)); return properties; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmListProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmListProperties.java index 3f77a21..3ae84b3 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmListProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmListProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -43,13 +43,21 @@ public class ElmListProperties extends HierarchyUIObjectProperties { private String multiSelectMode; private String mode; + public ElmListProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.horizontal = parser.getBoolean(); this.selectMode = getSelectModeMessage(parser.getChar()); - this.focusOnSelection = parser.getBoolean(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.focusOnSelection = parser.getBoolean(); + } this.multiSelect = parser.getBoolean(); - this.multiSelectMode = getMultiSelectModeMessage(parser.getChar()); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.multiSelectMode = getMultiSelectModeMessage(parser.getChar()); + } this.mode = getModeMessage(parser.getChar()); } @@ -57,12 +65,16 @@ public class ElmListProperties extends HierarchyUIObjectProperties { public List getProperties() { List properties = new ArrayList(); properties.add(new PropertyValue("horizontal", Boolean.toString(this.horizontal))); - properties.add(new PropertyValue("focusOnSelection", Boolean - .toString(this.focusOnSelection))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("focusOnSelection", Boolean + .toString(this.focusOnSelection))); + } properties.add(new PropertyValue("multiSelect", Boolean.toString(this.multiSelect))); properties.add(new PropertyValue("mode", this.mode)); properties.add(new PropertyValue("selectMode", this.selectMode)); - properties.add(new PropertyValue("multiSelectMode", this.multiSelectMode)); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("multiSelectMode", this.multiSelectMode)); + } return properties; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmMapProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmMapProperties.java index 2afd140..328967d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmMapProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmMapProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -48,6 +48,10 @@ public class ElmMapProperties extends HierarchyUIObjectProperties { private double regionLongitude; private double regionLatitude; + public ElmMapProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.zoom = parser.getInt(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmNotifyProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmNotifyProperties.java index 5c6f77a..4433b17 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmNotifyProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmNotifyProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -40,6 +40,10 @@ public class ElmNotifyProperties extends HierarchyUIObjectProperties { private boolean allowEvents; private double timeout; + public ElmNotifyProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.hAlign = parser.getFloat(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPanelProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPanelProperties.java index 68f27c4..d7b12d9 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPanelProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPanelProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -39,6 +40,10 @@ public class ElmPanelProperties extends HierarchyUIObjectProperties { private boolean hidden; private boolean scrollable; + public ElmPanelProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.orient = getOrientMessage(parser.getChar()); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotoProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotoProperties.java index e6ba417..f034e43 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotoProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotoProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -39,21 +40,33 @@ public class ElmPhotoProperties extends HierarchyUIObjectProperties { private boolean aspectFixed; private int size; + public ElmPhotoProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { - this.editable = parser.getBoolean(); - this.fillInside = parser.getBoolean(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.editable = parser.getBoolean(); + this.fillInside = parser.getBoolean(); + } this.aspectFixed = parser.getBoolean(); - this.size = parser.getInt(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.size = parser.getInt(); + } } @Override public List getProperties() { List properties = new ArrayList(); - properties.add(new PropertyValue("editable", Boolean.toString(this.editable))); - properties.add(new PropertyValue("fillInside", Boolean.toString(this.fillInside))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("editable", Boolean.toString(this.editable))); + properties.add(new PropertyValue("fillInside", Boolean.toString(this.fillInside))); + } properties.add(new PropertyValue("aspectFixed", Boolean.toString(this.aspectFixed))); - properties.add(new PropertyValue("size", Integer.toString(this.size))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("size", Integer.toString(this.size))); + } return properties; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotocamProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotocamProperties.java index a6a8cdd..23aac1e 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotocamProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPhotocamProperties.java @@ -24,13 +24,13 @@ * */ - package org.tizen.dynamicanalyzer.swap.model.data.hierarchy.elementary; import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -43,6 +43,10 @@ public class ElmPhotocamProperties extends HierarchyUIObjectProperties { private String zoomMode; private int[] imageSize = new int[2]; // width, height + public ElmPhotocamProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.paused = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPopupProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPopupProperties.java index d4eeb9a..e9491c1 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPopupProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmPopupProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -42,6 +43,10 @@ public class ElmPopupProperties extends HierarchyUIObjectProperties { private String orient; private double timeout; + public ElmPopupProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.hAlign = parser.getFloat(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmProgressbarProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmProgressbarProperties.java index e57a2e0..3ffc12f 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmProgressbarProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmProgressbarProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -41,6 +42,10 @@ public class ElmProgressbarProperties extends HierarchyUIObjectProperties { private boolean horizontal; private String unitFormat; + public ElmProgressbarProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.spanSize = parser.getInt(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmRadioProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmRadioProperties.java index 2bb435c..46e7ac2 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmRadioProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmRadioProperties.java @@ -29,6 +29,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -36,6 +37,10 @@ public class ElmRadioProperties extends HierarchyUIObjectProperties { private int stateValue; private int value; + public ElmRadioProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.stateValue = parser.getInt(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSegmentcontrolProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSegmentcontrolProperties.java index 11aad5f..29b4d6a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSegmentcontrolProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSegmentcontrolProperties.java @@ -30,12 +30,17 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; public class ElmSegmentcontrolProperties extends HierarchyUIObjectProperties { private int itemCount; + public ElmSegmentcontrolProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.itemCount = parser.getInt(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSliderProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSliderProperties.java index c55987b..56620f6 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSliderProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSliderProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -38,6 +39,10 @@ public class ElmSliderProperties extends HierarchyUIObjectProperties { private double value; private String indicatorFormat; + public ElmSliderProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.horizontal = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSpinnerProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSpinnerProperties.java index 2a75e46..4185782 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSpinnerProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmSpinnerProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -45,6 +46,10 @@ public class ElmSpinnerProperties extends HierarchyUIObjectProperties { private double value; private String labelFormat; + public ElmSpinnerProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.min = parser.getFloat(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmToolbarProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmToolbarProperties.java index eb04078..5f1b3f8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmToolbarProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmToolbarProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -45,6 +46,10 @@ public class ElmToolbarProperties extends HierarchyUIObjectProperties { private int standardPriority; private int itemCount; + public ElmToolbarProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.reorderMode = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmTooltipProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmTooltipProperties.java index b7c5c72..30b7895 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmTooltipProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmTooltipProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -37,6 +38,10 @@ public class ElmTooltipProperties extends HierarchyUIObjectProperties { private String style; private boolean windowMode; + public ElmTooltipProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.style = parser.getString(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmWinProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmWinProperties.java index c7588c8..22126a9 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmWinProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/elementary/ElmWinProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -66,6 +67,10 @@ public class ElmWinProperties extends HierarchyUIObjectProperties { private int[] screenDpi = new int[2]; // x, y private String type; + public ElmWinProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.iconified = parser.getBoolean(); @@ -84,7 +89,9 @@ public class ElmWinProperties extends HierarchyUIObjectProperties { this.urgent = parser.getBoolean(); this.rotation = parser.getInt(); this.sticky = parser.getBoolean(); - this.focusHighlightAnimate = parser.getBoolean(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.focusHighlightAnimate = parser.getBoolean(); + } this.aspect = parser.getFloat(); this.indicatorOpacity = getIndicatorOpacityMessage(parser.getChar()); this.demandAttention = parser.getBoolean(); @@ -121,8 +128,10 @@ public class ElmWinProperties extends HierarchyUIObjectProperties { properties.add(new PropertyValue("focusHighlightStyle", this.focusHighlightStyle)); properties.add(new PropertyValue("focusHighlightEnabled", Boolean .toString(this.focusHighlightEnabled))); - properties.add(new PropertyValue("focusHighlightAnimate", Boolean - .toString(this.focusHighlightAnimate))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("focusHighlightAnimate", Boolean + .toString(this.focusHighlightAnimate))); + } properties.add(new PropertyValue("urgent", Boolean.toString(this.urgent))); properties.add(new PropertyValue("rotation", Integer.toString(this.rotation))); properties.add(new PropertyValue("sticky", Boolean.toString(this.sticky))); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasBoxProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasBoxProperties.java index b22575a..44105b4 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasBoxProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasBoxProperties.java @@ -30,12 +30,17 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; public class EvasBoxProperties extends HierarchyUIObjectProperties { private double[] align = new double[2]; // horizontal, vertical + public EvasBoxProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.align[0] = parser.getFloat(); // horizontal diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasGridProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasGridProperties.java index 7341386..a3abda7 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasGridProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasGridProperties.java @@ -30,12 +30,17 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; public class EvasGridProperties extends HierarchyUIObjectProperties { private boolean mirrored; + public EvasGridProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.mirrored = parser.getBoolean(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasImageProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasImageProperties.java index 4a7ddce..65aa57d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasImageProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasImageProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -54,6 +55,10 @@ public class EvasImageProperties extends HierarchyUIObjectProperties { private int animatedFrameCount; // x, y, w, h private int stride; + public EvasImageProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.loadDpi = parser.getFloat(); @@ -71,15 +76,19 @@ public class EvasImageProperties extends HierarchyUIObjectProperties { this.borderCenterFill = getBorderCenterFillMessage(parser.getChar()); this.size[0] = parser.getInt(); // w this.size[1] = parser.getInt(); // h - this.sourceVisible = parser.getBoolean(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.sourceVisible = parser.getBoolean(); + } this.fill[0] = parser.getInt(); // x this.fill[1] = parser.getInt(); // y this.fill[2] = parser.getInt(); // w this.fill[3] = parser.getInt(); // h this.loadScaleDown = parser.getInt(); this.scaleHint = getScaleHintMessage(parser.getChar()); - this.sourceEvents = parser.getBoolean(); - this.animatedFrameCount = parser.getInt(); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + this.sourceEvents = parser.getBoolean(); + this.animatedFrameCount = parser.getInt(); + } this.stride = parser.getInt(); } @@ -99,12 +108,17 @@ public class EvasImageProperties extends HierarchyUIObjectProperties { .add(new PropertyValue("loadOrientation", Boolean.toString(this.loadOrientation))); properties.add(new PropertyValue("borderCenterFill", this.borderCenterFill)); properties.add(new PropertyValue("size", "[" + size[0] + ", " + size[1] + "]")); - properties.add(new PropertyValue("sourceVisible", Boolean.toString(this.sourceVisible))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties + .add(new PropertyValue("sourceVisible", Boolean.toString(this.sourceVisible))); + } properties.add(new PropertyValue("loadScaleDown", Integer.toString(this.loadScaleDown))); properties.add(new PropertyValue("scaleHint", this.scaleHint)); - properties.add(new PropertyValue("sourceEvents", Boolean.toString(this.sourceEvents))); - properties.add(new PropertyValue("animatedFrameCount", Integer - .toString(this.animatedFrameCount))); + if (protocolVersion != Protocol.VERSION_30_UIHV) { + properties.add(new PropertyValue("sourceEvents", Boolean.toString(this.sourceEvents))); + properties.add(new PropertyValue("animatedFrameCount", Integer + .toString(this.animatedFrameCount))); + } properties.add(new PropertyValue("stride", Integer.toString(this.stride))); return properties; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasLineProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasLineProperties.java index 3ae22ce..53c650d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasLineProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasLineProperties.java @@ -30,12 +30,17 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; public class EvasLineProperties extends HierarchyUIObjectProperties { private int[] xy = new int[4]; // x1, y1, x2, y2 + public EvasLineProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.xy[0] = parser.getInt(); // x1 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasProperties.java index 1f8895d..363037a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -50,6 +51,10 @@ public class EvasProperties extends HierarchyUIObjectProperties { private int[] padding = new int[4]; // left, right, top, bottom private String renderOp; + public EvasProperties(Protocol protocolVersion) { + super(protocolVersion); + } + public int[] getGeometry() { return geometry; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTableProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTableProperties.java index 7387feb..4ce6457 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTableProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTableProperties.java @@ -29,6 +29,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -41,6 +42,10 @@ public class EvasTableProperties extends HierarchyUIObjectProperties { private int colSize; private int rowSize; + public EvasTableProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.homogeneous = getHomogeneousMessage(parser.getChar()); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextProperties.java index a1b61bc..98eeed1 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; import org.tizen.dynamicanalyzer.util.Logger; @@ -48,6 +49,10 @@ public class EvasTextProperties extends HierarchyUIObjectProperties { private int[] stylePad = new int[4]; // left, right, top, bottom private String direction; + public EvasTextProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.font = parser.getString(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextblockProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextblockProperties.java index 45c9484..98d5d92 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextblockProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextblockProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -40,6 +41,10 @@ public class EvasTextblockProperties extends HierarchyUIObjectProperties { private boolean legacyNewline; private String textMarkup; + public EvasTextblockProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.replaceChar = parser.getString(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextgridProperties.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextgridProperties.java index 5a33e1e..599bba6 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextgridProperties.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/model/data/hierarchy/evas/EvasTextgridProperties.java @@ -30,6 +30,7 @@ import java.util.ArrayList; import java.util.List; import org.tizen.dynamicanalyzer.communicator.ProtocolParser; +import org.tizen.dynamicanalyzer.protocol.Protocol; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.HierarchyUIObjectProperties; import org.tizen.dynamicanalyzer.swap.model.data.hierarchy.PropertyValue; @@ -37,6 +38,10 @@ public class EvasTextgridProperties extends HierarchyUIObjectProperties { private int[] size = new int[2]; // w, h private int[] cellSize = new int[2]; // w, h + public EvasTextgridProperties(Protocol protocolVersion) { + super(protocolVersion); + } + @Override public void parsePropertiesFromByte(ProtocolParser parser) { this.size[0] = parser.getInt(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/platform/ui/SettingSaveTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/platform/ui/SettingSaveTable.java index ca6ef9b..b45c87a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/platform/ui/SettingSaveTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/swap/platform/ui/SettingSaveTable.java @@ -34,6 +34,7 @@ import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.path.PathManager; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; import org.tizen.dynamicanalyzer.utils.AnalyzerUtil; @@ -87,5 +88,4 @@ public class SettingSaveTable extends DATableComposite { } table.update(); } - } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/common/TimeLineChartKeyListener.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/common/TimeLineChartKeyListener.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/common/explorer/DAFileExplorerEmptyCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/common/explorer/DAFileExplorerEmptyCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListTable.java index 6e14cfe..c1326f5 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListTable.java @@ -32,6 +32,7 @@ import java.util.ArrayList; import java.util.HashMap; import java.util.List; +import org.eclipse.nebula.widgets.grid.GridColumn; import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; @@ -43,8 +44,11 @@ import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.database.SqlConnectionManager; import org.tizen.dynamicanalyzer.error.ErrorCodeManager; import org.tizen.dynamicanalyzer.logparser.LogCenterConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.swap.model.data.FileData; +import org.tizen.dynamicanalyzer.ui.file.data.FileAccessorDB; +import org.tizen.dynamicanalyzer.ui.file.data.FileApiDB; import org.tizen.dynamicanalyzer.ui.file.manager.FileDataManager; import org.tizen.dynamicanalyzer.ui.file.model.FileAccessor; import org.tizen.dynamicanalyzer.ui.file.model.FileEvent; @@ -55,10 +59,9 @@ import org.tizen.dynamicanalyzer.ui.widgets.table.DATableDataFormat; import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.dynamicanalyzer.utils.Formatter; - public class FileApiListTable extends DAApiListTableComposite { private FileDataManager fileDataManager = FileDataManager.getInstance(); - + public FileApiListTable(Composite parent, int compStyle, int tableStyle) { super(parent, compStyle, tableStyle); table.addSelectionListener(new SelectionListener() { @@ -88,10 +91,8 @@ public class FileApiListTable extends DAApiListTableComposite { endTime = itemTime; } } - DASelectionData selData = new DASelectionData( - FilePage.apilistViewID, startTime, endTime, items, - table); - + DASelectionData selData = new DASelectionData(FilePage.apilistViewID, startTime, endTime, items, table); + AnalyzerManager.getCurrentPage().updateView(selData); } @@ -103,36 +104,43 @@ public class FileApiListTable extends DAApiListTableComposite { @Override protected List makeTableInput() { - FileApiListView view = (FileApiListView) AnalyzerManager - .getCurrentPage().getView(FilePage.apilistViewID); - - if(view == null ) { + FileApiListView view = (FileApiListView) AnalyzerManager.getCurrentPage().getView(FilePage.apilistViewID); + + if (view == null) { return null; } long rangeStartTime = view.getRangeStartTime(); long rangeEndTime = view.getRangeEndTime(); - + HashMap findStartAPITableIndexHashMap = new HashMap(); HashMap findStartTimeHashMap = new HashMap(); List removeTableIndex = new ArrayList(); List input = new ArrayList(); - + List filterList = getFilterPropertyList(); + FileSelectedData selectedData = fileDataManager.getSelectedData(); - - if(selectedData == null) { + + if (selectedData == null) { return null; } - - ResultSet rs = fileDataManager.getApiDB().selectAPI( - selectedData.getFileId(), - selectedData.getAccessorId(), - selectedData.isParentChart()); + + ResultSet rs = null; + if (!filterList.isEmpty()) { // filtering by user + List whereClause = convertFilterProperty2Query(filterList); + rs = fileDataManager.getApiDB().selectAPI(selectedData.getFileId(), selectedData.getAccessorId(), + selectedData.isParentChart(), whereClause); + } else { + rs = fileDataManager.getApiDB().selectAPI(selectedData.getFileId(), selectedData.getAccessorId(), + selectedData.isParentChart(), null); + } + FileAccessor accessor = selectedData.getFileAccessor(); boolean isParentChart = selectedData.isParentChart(); String filePath = null; int pid = -1; int tid = -1; + if (rs != null) { try { int i = -1; @@ -140,7 +148,7 @@ public class FileApiListTable extends DAApiListTableComposite { while (rs.next()) { i++; index++; - + List contentText = new ArrayList(); List contentData = new ArrayList(); Integer startLogIndex = 0; @@ -154,80 +162,98 @@ public class FileApiListTable extends DAApiListTableComposite { long fileSize = rs.getLong(7); long ioSize = rs.getLong(8); String returns = rs.getString(9); - String args = rs.getString(10); - - if(isParentChart){ + String args = rs.getString(10); + + if (isParentChart) { filePath = rs.getString(11); pid = rs.getInt(12); - tid = rs.getInt(13); - }else{ + tid = rs.getInt(13); + } else { filePath = accessor.getFilePath(); pid = accessor.getPid(); tid = accessor.getTid(); } - - FileEvent fileEvent = new FileEvent(seq, filePath, pid, - tid, fd, fdApiType, apiId, time, fileSize, ioSize, - args, returns, errno); - + + FileEvent fileEvent = new FileEvent(seq, filePath, pid, tid, fd, fdApiType, apiId, time, fileSize, + ioSize, args, returns, errno); + String apiName = Global.getFunctionName(apiId); + String errMsg = getErrorMessage(errno); long startTime = 0; - - boolean isExistStartTimeLog = false; + String startTimeStr = ""; + String elapsedTime = ""; //$NON-NLS-1$ + + // case 1. have start/end events if (fdApiType == LogCenterConstants.FD_API_TYPE_READ_START || fdApiType == LogCenterConstants.FD_API_TYPE_WRITE_START - || fdApiType == LogCenterConstants.FD_API_TYPE_LOCK_START) { + || fdApiType == LogCenterConstants.FD_API_TYPE_LOCK_START) { + String keString = apiName + pid + tid + fd; findStartAPITableIndexHashMap.put(keString, i); findStartTimeHashMap.put(i, time); + + // start time + contentText.add(Formatter.toTimeFormat(time)); + contentData.add(Long.toString(time)); + + // elapsed time + contentText.add("-");//$NON-NLS-1$ + contentData.add("-");//$NON-NLS-1$ + } else if (fdApiType == LogCenterConstants.FD_API_TYPE_READ_END || fdApiType == LogCenterConstants.FD_API_TYPE_WRITE_END - || fdApiType == LogCenterConstants.FD_API_TYPE_LOCK_END) { + || fdApiType == LogCenterConstants.FD_API_TYPE_LOCK_END) { + index--; String keString = apiName + pid + tid + fd; startLogIndex = findStartAPITableIndexHashMap.get(keString); - findStartAPITableIndexHashMap.remove(keString); - if (null != startLogIndex) { - contentText.add(input.get(startLogIndex.intValue()) - .getText().get(1)); // start time - contentData.add(input.get(startLogIndex.intValue()) - .getText().get(1)); + String timeFormat = ""; + if (null != startLogIndex) { + // start time startTime = findStartTimeHashMap.get(startLogIndex); - String timeFormat = Formatter - .toTimeFormat(time - startTime); - String removeTimeFormat = timeFormat.replace( - "00:", CommonConstants.EMPTY);//$NON-NLS-1$ + startTimeStr = Formatter.toTimeFormat(startTime); + + contentText.add(startTimeStr); + contentData.add(Long.toString(startTime)); + + findStartAPITableIndexHashMap.remove(keString); + findStartTimeHashMap.remove(startLogIndex); - contentText.add(removeTimeFormat); // elapsed time + // elapsed time + timeFormat = Formatter.toTimeFormat(time - startTime); + elapsedTime = timeFormat.replace("00:", CommonConstants.EMPTY);//$NON-NLS-1$ + + contentText.add(elapsedTime); contentData.add(Long.toString(time - startTime)); - - isExistStartTimeLog = true; + + // to remove start log from table removeTableIndex.add(startLogIndex); } else { - contentText.add(Formatter.toTimeFormat(time)); // start// - contentData.add(Long.toString(time)); - contentText.add("00.000");//$NON-NLS-1$ - contentData.add("00.000");//$NON-NLS-1$ + // when having no start event(in case of running + // process), do not show + continue; } - } - if (!isExistStartTimeLog) { - contentText.add(Formatter.toTimeFormat(time)); // start time + // case 2. have no end event. ex) open, close.. + } else { + // start time + contentText.add(Formatter.toTimeFormat(time)); contentData.add(Long.toString(time)); - contentText.add("00.000");//$NON-NLS-1$ //elapsed time - contentData.add("00.000");//$NON-NLS-1$ + // elapsed time + contentText.add("00.000");//$NON-NLS-1$ + contentData.add("00.000");//$NON-NLS-1$ } contentText.add(0, Integer.toString(index)); contentData.add(0, Integer.toString(index)); - + contentText.add(Integer.toString(pid)); contentData.add(Integer.toString(pid)); contentText.add(Integer.toString(tid)); contentData.add(Integer.toString(tid)); - + contentText.add(Long.toString(fd)); contentData.add(Long.toString(fd)); @@ -236,23 +262,18 @@ public class FileApiListTable extends DAApiListTableComposite { contentText.add(args); contentData.add(args); - + contentText.add(returns); contentData.add(returns); - String errMsg = ErrorCodeManager.getInatance() - .getErrorCode(errno).name(); - if (null == errMsg) { - errMsg = "undefined error code"; //$NON-NLS-1$ - } - contentText.add(errMsg); contentData.add(errMsg); - + // create DATableDataFormat DATableDataFormat tableData = new DATableDataFormat(seq); tableData.setLogData(fileEvent); tableData.getData().addAll(contentData); + TableInput tableInput = new TableInput(); tableInput.setText(contentText); tableInput.setData(tableData); @@ -271,23 +292,81 @@ public class FileApiListTable extends DAApiListTableComposite { SqlConnectionManager.releaseResultSet(rs); } } - + int removeCount = 0; for (int index : removeTableIndex) { int removeIndex = index - removeCount; - if (removeIndex > 0) { + if (removeIndex >= 0) { input.remove(removeIndex); removeCount++; } } + + removeTableDataByFilterProperty(input, filterList); return input; } + private void removeTableDataByFilterProperty(List targetList, List filterList) { + if (filterList.size() == 0) { + return; + } + List removeCandidateList = new ArrayList(); + for (int i = 0; i < targetList.size(); i++) { + TableInput tableInput = targetList.get(i); + boolean delete = false; + for (int a = 0; a < filterList.size(); a++) { + FilterProperty property = filterList.get(a); + String targetContent = tableInput.getText().get(property.getColumnIndex()).toLowerCase(); + if (!targetContent.contains(property.getKeyWord().toLowerCase())) { + delete = true; + break; + } + } + if (delete) { + removeCandidateList.add(tableInput); + } + } + targetList.removeAll(removeCandidateList); + } + + // get column name from index of filter table + @Override + protected String getFilteredColumnName(int index) { + String columnName = null; + switch (index) { + case 3: + columnName = FileAccessorDB.COLUMN.PID.name; + break; + case 4: + columnName = FileAccessorDB.COLUMN.TID.name; + break; + case 5: + columnName = FileApiDB.COLUMN.FD.name; + break; + case 7: + columnName = addLowerOperation(FileApiDB.COLUMN.ARGUMENT.name); + break; + case 8: + columnName = FileApiDB.COLUMN.RETURN_VALUE.name; + break; + default: + break; + } + return columnName; + } + + private String getErrorMessage(long erroNo) { + String errMsg = ErrorCodeManager.getInatance().getErrorCode(erroNo).name(); + if (null == errMsg) { + errMsg = "undefined error code"; //$NON-NLS-1$ + } + return errMsg; + } + protected void actionSetStartEnd(int type) { GridItem item = table.getItem(mousePoint); if (null != item) { - FileData data = (FileData) ((DATableDataFormat) item.getData()) - .getLogData(); + FileData data = (FileData) ((DATableDataFormat) item.getData()).getLogData(); long time = data.getTime(); double startTime = -1; double endTime = -1; @@ -295,21 +374,33 @@ public class FileApiListTable extends DAApiListTableComposite { if (type == START_TIME) { rangeDataManager.setMarkerStartTime(time); startTime = time / TimelineConstants.MEGA_DOUBLE; - endTime = rangeDataManager.getMarkerEndTime() - / TimelineConstants.MEGA_DOUBLE; + endTime = rangeDataManager.getMarkerEndTime() / TimelineConstants.MEGA_DOUBLE; } else if (type == END_TIME) { rangeDataManager.setMarkerEndTime(time); endTime = time / TimelineConstants.MEGA_DOUBLE; - startTime = rangeDataManager.getMarkerStartTime() - / TimelineConstants.MEGA_DOUBLE; + startTime = rangeDataManager.getMarkerStartTime() / TimelineConstants.MEGA_DOUBLE; } - FileChartView chartview = (FileChartView) (AnalyzerManager - .getCurrentPage().getView(FilePage.chartViewID)); - if(chartview != null) { + FileChartView chartview = (FileChartView) (AnalyzerManager.getCurrentPage().getView(FilePage.chartViewID)); + if (chartview != null) { chartview.setRangeMarker(startTime, endTime); } } } + + public boolean[] getColumnVisibility() { + if (null == table) + return null; + + GridColumn[] columns = table.getColumns(); + int size = columns.length; + boolean[] columnsVisibility = new boolean[size]; + + for (int i = 1; i < size; i++) { // except column "#" as index number + columnsVisibility[i] = columns[i].getVisible(); + } + + return columnsVisibility; + } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListView.java index 0b7bef2..308cb41 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileApiListView.java @@ -38,11 +38,12 @@ import org.tizen.dynamicanalyzer.ui.file.manager.FileDataManager; import org.tizen.dynamicanalyzer.ui.file.model.FileSelectedData; import org.tizen.dynamicanalyzer.ui.range.RangeDataManager; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class FileApiListView extends DAViewComposite { +public class FileApiListView extends DAAdvancedViewComposite { private long analysisStartTime = 0; private long analysisEndTime = 0; private int preSelectionPId = 1; @@ -80,7 +81,7 @@ public class FileApiListView extends DAViewComposite { FileDataManager manager = FileDataManager.getInstance(); public FileApiListView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(FilePageLabels.FILE_API_LIST_VIEW_TITLE); @@ -97,6 +98,7 @@ public class FileApiListView extends DAViewComposite { tableComp.setTableName(FilePageLabels.FILE_API_LIST_VIEW_TITLE); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileDetailInfoView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileDetailInfoView.java index f663b0b..62cfe65 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileDetailInfoView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FileDetailInfoView.java @@ -140,7 +140,7 @@ public class FileDetailInfoView extends DAViewComposite { ResultSet rs = fileChartManager.getApiDB().selectAPI( selectData.getFileId(), selectData.getAccessorId(), - selectData.isParentChart()); + selectData.isParentChart(), null); boolean isParentChart = selectData.isParentChart(); FileAccessor accessor = selectData.getFileAccessor(); String path = null; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FilePage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/FilePage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileAccessorDB.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileAccessorDB.java index 1da96dd..52757e0 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileAccessorDB.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileAccessorDB.java @@ -52,8 +52,8 @@ public class FileAccessorDB extends DBTable { IS_TARGET(6, "IS_TARGET"); - private final int index; - private final String name; + public final int index; + public final String name; private COLUMN(int index, String name) { this.index = index; this.name = name; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDB.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDB.java index 80c8f55..2c9e324 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDB.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDB.java @@ -183,14 +183,21 @@ public class FileApiDB extends DBTable { } // for updating api table view and detail view - public ResultSet selectAPI(int fileId, int accessorId, - boolean isParentChart) { + public ResultSet selectAPI(int fileId, int accessorId, boolean isParentChart, + List whereClause) { String query = null; if (isParentChart) { query = String.format(SELECT_APIS_FOR_PARENT, fileId); }else{ query = String.format(SELECT_APIS_FOR_CHILD, accessorId); } + + if(whereClause != null && whereClause.size() > 0) { + for(int i = 0; i < whereClause.size(); i++) { + query += " and " + whereClause.get(i); + } + } + return SqlConnectionManager.executeQueryRS(query); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/manager/FileDataMaker.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/manager/FileDataMaker.java index 0e56012..f834d31 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/manager/FileDataMaker.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/file/manager/FileDataMaker.java @@ -186,7 +186,7 @@ public class FileDataMaker { input.getTid(), input.getFdValue(), input.getFdApiType(), input.getApiId(), input.getTime(), input.getFileSize(), input.getSize(), input.getArgs(), input.getReturn(), input.getErrno(), true); - + addFileEvent(fileEventList, event, input); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/HierarchyPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/HierarchyPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/HierarchyTreeView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/HierarchyTreeView.java index 2a32d10..86f514d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/HierarchyTreeView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/HierarchyTreeView.java @@ -56,6 +56,7 @@ import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.DAState; import org.tizen.dynamicanalyzer.communicator.DACommunicator; import org.tizen.dynamicanalyzer.communicator.UnsupportedProtocolException; +import org.tizen.dynamicanalyzer.handlers.UIAction; import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; import org.tizen.dynamicanalyzer.nl.UIHierarchyPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; @@ -76,8 +77,8 @@ import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.dynamicanalyzer.util.WorkbenchUtil; import org.tizen.dynamicanalyzer.widgets.button.DACustomButton; import org.tizen.dynamicanalyzer.widgets.button.DACustomButtonClickEventListener; -import org.tizen.dynamicanalyzer.widgets.da.base.DADialog; import org.tizen.dynamicanalyzer.widgets.da.base.IndeterminateProgressDialog; +import org.tizen.dynamicanalyzer.widgets.da.base.DADialog; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.workbench.LayoutManager; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/tool/HierarchyTreeExporter.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/tool/HierarchyTreeExporter.java index 3f94f24..daaf189 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/tool/HierarchyTreeExporter.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/hierarchy/tree/tool/HierarchyTreeExporter.java @@ -43,6 +43,7 @@ import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.FileDialog; import org.eclipse.swt.widgets.Shell; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.handlers.UIAction; import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; import org.tizen.dynamicanalyzer.nl.UIHierarchyPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackTable.java index 86ad23f..080c07d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackTable.java @@ -34,11 +34,13 @@ import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.SWT; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; +import org.eclipse.swt.graphics.Rectangle; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.project.callstack.RuntimeCallstackManager; import org.tizen.dynamicanalyzer.swap.model.data.LogData; @@ -76,6 +78,8 @@ public class CallstackTable extends DATableComposite { public void widgetDefaultSelected(SelectionEvent e) { } }); + + applyFilterImage(); } @Override @@ -161,6 +165,8 @@ public class CallstackTable extends DATableComposite { return; } + // TODO : make GridItem using filter property data + GridItem gridItem = new GridItem(table, SWT.NONE); // setData block diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackView.java index 02c74f8..23aed89 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/callstack/CallstackView.java @@ -82,6 +82,7 @@ public class CallstackView extends DAViewComposite { callstackTableComp.setColumnVisibility(columnVisibility); contents.addControlListener(new TableColumnSizePackListener(callstackTableComp, columnSizes)); +// setView(this); } public void setObservingViews(String[] viewIds) { diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/score/ScoreView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/score/ScoreView.java index 9302496..89aa05f 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/score/ScoreView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/score/ScoreView.java @@ -224,7 +224,7 @@ public class ScoreView extends DAViewComposite { @Override public void updateView() { failCount = SummaryDataManager.getInstance().getFailedApiDataMaker() - .getFailedApiDataFromDB(Toolbar.INSTANCE.getSelectedPid()).size(); + .getFailedApiDataFromDB(Toolbar.INSTANCE.getSelectedPid(), null).size(); leakSize = AnalyzerManager.getNewLeakDetector().getLeakHash().size(); warningSize = AnalyzerManager.getWarningChecker().getWarningData().size(); columnValue.set(0, failCount); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/screenshot/ImageViewer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/screenshot/ImageViewer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/InteractivePage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/InteractivePage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTable.java index 4a864d4..7bea98c 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTable.java @@ -45,6 +45,7 @@ import org.eclipse.swt.widgets.Listener; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.ui.interactive.InteractivePage; import org.tizen.dynamicanalyzer.ui.interactive.data.InteractiveDataManager; @@ -200,14 +201,17 @@ public class InteractiveTable extends DATreeComposite { long tableID = 0; Collections.sort(parsedUIDataList); + List filterList = getFilterPropertyList(); List output = new ArrayList(); for (int i = 0; i < parsedUIDataList.size(); i++) { InteractiveUIData valueData = parsedUIDataList.get(i); if (valueData != null) { tableID = setUIDataID(valueData, tableID); TreeInput valueInput = makeInput(valueData, valueData.getTime(), false); - makeChildTree(valueData, valueInput, valueData.getTime(), valueData.getName()); - output.add(valueInput); + boolean isChildAdded = makeChildTree(valueData, valueInput, valueData.getTime(), valueData.getName(), filterList); + if (isChildAdded || checkFilter(valueInput, filterList)) { + output.add(valueInput); + } } else { output.add(null); } @@ -265,10 +269,25 @@ public class InteractiveTable extends DATreeComposite { return output; } - private void makeChildTree(InteractiveUIData parentData, TreeInput parentInput, long time, String parentName) { + private boolean checkFilter(TreeInput input, List filterList) { + if (filterList.isEmpty()) { + return true; + } + List textList = input.getText(); + for (int i = 0; i < filterList.size(); i++) { + FilterProperty prop = filterList.get(i); + if (textList.get(prop.getColumnIndex()).contains(prop.getKeyWord()) == false) { + return false; + } + } + return true; + } + + private boolean makeChildTree(InteractiveUIData parentData, TreeInput parentInput, long time, String parentName, List filterList) { + boolean isChildAdded = false; List children = parentData.getChildren(); if (children == null) { - return; + return isChildAdded; } for (int i = 0; i < children.size(); i++) { InteractiveUIData data = children.get(i); @@ -279,10 +298,14 @@ public class InteractiveTable extends DATreeComposite { data.setName("[" + i + "]"); } TreeInput input = makeInput(data, time, true); - makeChildTree(data, input, time, data.getName()); - parentInput.getChildren().add(input); - input.setParent(parentName); + boolean isGrandChildAdded = makeChildTree(data, input, time, data.getName(), filterList); + if (isGrandChildAdded || checkFilter(input, filterList)) { + parentInput.getChildren().add(input); + input.setParent(parentName); + isChildAdded = true; + } } + return isChildAdded; } private long setUIDataID(InteractiveUIData uiData, long tableRowID) { diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableView.java index e03966f..83fd775 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/interactive/table/InteractiveTableView.java @@ -38,11 +38,11 @@ import org.tizen.dynamicanalyzer.model.ColumnData; import org.tizen.dynamicanalyzer.nl.InteractivePageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.interactive.model.InteractiveInfo; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class InteractiveTableView extends DAViewComposite { +public class InteractiveTableView extends DAAdvancedViewComposite { public static final String ID = InteractiveTableView.class.getName(); protected InteractiveTable treeComp = null; protected List columnData = null; @@ -59,7 +59,7 @@ public class InteractiveTableView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_NONE }; public InteractiveTableView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(InteractivePageLabels.INTERACTIVE_TABLE_VIEW_TITLE); @@ -79,6 +79,7 @@ public class InteractiveTableView extends DAViewComposite { treeComp.setTableToolTipEnable(false); contents.addControlListener(new TableColumnSizePackListener(treeComp, columnSizes)); + setTable(treeComp); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/ContextSwitchingChartView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/ContextSwitchingChartView.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelListTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelListTable.java index 99a08eb..acd6408 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelListTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelListTable.java @@ -39,6 +39,7 @@ import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; import org.tizen.dynamicanalyzer.database.DBConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.ui.kernel.data.ContextDataDBTable; import org.tizen.dynamicanalyzer.ui.kernel.data.FunctionDataDBTable; @@ -255,5 +256,4 @@ public class KernelListTable extends DAWindowingTableComposite { return timestr; } - } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/KernelPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/data/KernelDataMaker.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/kernel/data/KernelDataMaker.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryAllocationTraceTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryAllocationTraceTableView.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryChartView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryChartView.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryDetailsTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryDetailsTableView.java old mode 100755 new mode 100644 index 9df6d74..cceedf2 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryDetailsTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryDetailsTableView.java @@ -81,10 +81,10 @@ public class MemoryDetailsTableView extends DAViewComposite { DASelectionData selData = (DASelectionData) vdata; if(selData.getStartTime() == selData.getEndTime()) { - tableComp.setSelectionRange((long)0, (long)0, selData.getStartTime()); + tableComp.setSelectionRange((long)0, (long)0); } else { - tableComp.setSelectionRange(selData.getStartTime(), selData.getEndTime(), (long) -1); + tableComp.setSelectionRange(selData.getStartTime(), selData.getEndTime()); } tableComp.updateTable(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryMapView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryMapView.java old mode 100755 new mode 100644 index 7d987f3..301f9d2 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryMapView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryMapView.java @@ -29,6 +29,7 @@ import org.eclipse.swt.layout.FillLayout; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; import org.tizen.dynamicanalyzer.common.AnalyzerManager; +import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.nl.MemoryPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.memory.table.MemoryMapTable; @@ -65,7 +66,10 @@ public class MemoryMapView extends DAViewComposite { @Override public void updateView(DAViewData data) { - + //if (data instanceof DASelectionData == false) { + // return; + //} + //DASelectionData seldata = (DASelectionData) data; } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryStatisticsTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/MemoryStatisticsTableView.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/HeapMemoryChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/HeapMemoryChart.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/MemoryChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/MemoryChart.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/MemoryChartBoard.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/MemoryChartBoard.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/ProcessMemoryChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/ProcessMemoryChart.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/SystemMemoryChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/chart/SystemMemoryChart.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/AllocateDBTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/AllocateDBTable.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/FreeDBTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/FreeDBTable.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/MemoryDataManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/MemoryDataManager.java old mode 100755 new mode 100644 index d68cafe..ac030c0 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/MemoryDataManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/MemoryDataManager.java @@ -206,7 +206,7 @@ public class MemoryDataManager extends PageDataManager { } } - private void makeAllocData(MemoryData log) { + public void makeAllocData(MemoryData log) { ArrayList dbAllocData = new ArrayList(); MemoryData mData = log; @@ -228,7 +228,7 @@ public class MemoryDataManager extends PageDataManager { memoryAllocDataList.add(dbAllocData); } - private void makeFreeData(MemoryData log) { + public void makeFreeData(MemoryData log) { ArrayList dbFreeData = new ArrayList(); MemoryData mData = log; @@ -242,157 +242,6 @@ public class MemoryDataManager extends PageDataManager { memoryfreeDataList.add(dbFreeData); } - private void GetAllocationData(List memoryLogList) { - int size = memoryLogList.size(); - for (int i = 0; i < size; i++) { - MemoryData logData = (MemoryData) memoryLogList.get(i); - if (allocByteMap.get(logData.getPid()) == null) { - allocByteMap.put(Integer.valueOf(logData.getPid()), new Long(0)); - libraryAllocByteMap.put(Integer.valueOf(logData.getPid()), new HashMap()); - } - - int memApiType = logData.getMemoryApiType(); - int internalFlag = logData.getInternalCall(); - long errorNo = logData.getErrno(); - - /* - * Check library allocation - */ - BinaryInfo binaryInfo = null; - Project project = Global.getProject(); - ProcessMemoryMap pmap = project.getProcessInformation(logData.getPid()).getProcessMemoryMap(logData.getTime()); - - if (pmap != null) { - LibraryObject lib = pmap.getLibraryByAddress(logData.getCallerPcAddr()); - if (lib != null && lib != pmap.getMainbinary()) { - binaryInfo = project.getDeviceStatusInfo().getBinaryInfo(lib.getBinaryID()); - } - } - - if (errorNo == 0 && MEM_USER == internalFlag) { - if (MEM_API_TYPE_ALLOC == memApiType || MEM_API_TYPE_FREE == memApiType) { - addNewSeriesUserAllocData(memApiType, logData, binaryInfo); - } - } - - /* - * Save allocation and free api call - */ - if(MEM_API_TYPE_ALLOC == memApiType) { - makeAllocData(logData); - } - else if(MEM_API_TYPE_FREE == memApiType) { - makeFreeData(logData); - } - } - - } - - private void GetSystemMemoryData(List systemLogList) { - ArrayList> systemDataList = new ArrayList>(); - ArrayList> targetProcessDataList = new ArrayList>(); - - int size = systemLogList.size(); - for (int i = 0; i < size; i++) { - SystemData log = (SystemData) systemLogList.get(i); - - /* - * Make information for other process - */ - List pIDList = new ArrayList(); - List processLoadList = new ArrayList(); - String[] processLoadDatas = log.getOtherProcessLoad().split(CommonConstants.COMMA); - for (int ii = 0; ii < processLoadDatas.length; ii++) { - String processLoad = processLoadDatas[ii]; - if (processLoad == null || processLoad.isEmpty()) { - continue; - } - pIDList.add(new Integer(processLoad)); - processLoadList.add(processLoadDatas[++ii]); - } - - /* - * Make SystemData Table data - */ - ArrayList dbSystemData = new ArrayList(); - dbSystemData.add(new Long(log.getTime())); - dbSystemData.add(new Long(log.getSystemMemoryUsed())); - dbSystemData.add(pIDList); - dbSystemData.add(processLoadList); - systemDataList.add(dbSystemData); - - /* - * Make target Process Table data - */ - ProcessProfileData[] targetProcessList = log.getProcessProfileDataList(); - if (targetProcessList != null) { - for (int j = 0; j < targetProcessList.length; j++) { - ProcessProfileData process = targetProcessList[j]; - - ArrayList dbTargetProcessData = new ArrayList(); - dbTargetProcessData.add(new Long(log.getTime())); - dbTargetProcessData.add(new Integer(process.getPid())); - dbTargetProcessData.add(new Float(process.getProcessLoad())); - dbTargetProcessData.add(new Long(process.getVirtualMemory())); - dbTargetProcessData.add(new Long(process.getResidentMemory())); - dbTargetProcessData.add(new Long(process.getSharedMemory())); - dbTargetProcessData.add(new Long(process.getPssMemory())); - dbTargetProcessData.add(new Integer(process.getThreadCount())); - dbTargetProcessData.add(new Long(process.getTotalAllocSize())); - - /* - * Set inform for Heap allocation - */ - List binaryIDList = new ArrayList(); - List allocByteList = new ArrayList(); - binaryIDList.add(appAllocSeriesID); - if (allocByteMap.get(process.getPid()) == null) { - allocByteList.add(new Long(0)); - } else { - allocByteList.add(allocByteMap.get(process.getPid())); - } - - Map libraryList = libraryAllocByteMap.get(process.getPid()); - if (libraryList == null) { - libraryList = new HashMap(); - } - - Iterator iter = libraryList.keySet().iterator(); - while (iter.hasNext()) { - Integer binaryID = iter.next(); - binaryIDList.add(binaryID); - allocByteList.add(libraryList.get(binaryID)); - } - dbTargetProcessData.add(binaryIDList); - dbTargetProcessData.add(allocByteList); - - /* - * Set inform for Thread - */ - List threadIdList = new ArrayList(); - List threadLoadList = new ArrayList(); - // TODO Remove unnecessary String parsing. first Fix in SystemData.java - String[] threadLoads = process.getThreadLoad().split(CommonConstants.COMMA); - for (int iii = 0; iii < threadLoads.length; iii++) { - String threadLoad = threadLoads[iii]; - if (threadLoad == null || threadLoad.isEmpty()) { - continue; - } - threadIdList.add(new Integer(threadLoad)); - threadLoadList.add(threadLoads[++iii]); - } - dbTargetProcessData.add(threadIdList); - dbTargetProcessData.add(threadLoadList); - - targetProcessDataList.add(dbTargetProcessData); - } - } - } - - systemMemoryDBInserter.pushData(systemDataList); - processMemoryDBInserter.pushData(targetProcessDataList); - } - public List> getSystemDataFromDB(long start, long end) { String where = "WHERE SAMPLING_TIME BETWEEN " + start + " AND " + end + " ORDER BY SAMPLING_TIME"; @@ -417,28 +266,47 @@ public class MemoryDataManager extends PageDataManager { return output; } - public List getColumnLongFromDB(String tableName, String columnName, String timecolumn, long start, long end) { - return getColumnLongFromDB(tableName, columnName, timecolumn, 0, start, end); + public List getColumnLongFromDB(String tableName, String columnName, String timecolumn, long start, long end) { + List output = new ArrayList(); + String query; + + if(start == 0 && end == 0) { + query = String.format("SELECT %s FROM %s", + columnName, tableName); + } + else { + query = String.format("SELECT %s FROM %s WHERE %s BETWEEN %s and %s", + columnName, tableName, timecolumn, start, end); + } + + ResultSet rs = SqlConnectionManager.executeQueryRS(query); + if (rs != null) { + try { + while (rs.next()) { + output.add(rs.getLong(1)); + } + } catch (SQLException e) { + Logger.exception(e); + } finally { + SqlConnectionManager.releaseResultSet(rs); + } + } + + return output; } - public List getColumnLongFromDB(String tableName, String columnName, String timecolumn, int targetID, long start, long end) { + public List getColumnLongFromDB(String tableName, String columnName, String timecolumn, + int targetID, long start, long end) { List output = new ArrayList(); String query; if(start == 0 && end == 0) { - query = String.format("SELECT %s FROM %s", columnName, tableName); - - if(targetID != 0) { - query += " WHERE PID = " + targetID; - } + query = String.format("SELECT %s FROM %s WHERE PID = %s", + columnName, tableName, targetID); } else { - query = String.format("SELECT %s FROM %s WHERE %s BETWEEN %s AND %s", + query = String.format("SELECT %s FROM %s WHERE %s BETWEEN %s and %s AND PID = %s", columnName, tableName, timecolumn, start, end, targetID); - - if(targetID != 0) { - query += " AND PID = " + targetID; - } } ResultSet rs = SqlConnectionManager.executeQueryRS(query); @@ -490,7 +358,8 @@ public class MemoryDataManager extends PageDataManager { return processedResult; } - public Map>> getTargetProcessDataMapFromDB(long start, long end, int targetPID) { + public Map>> getTargetProcessDataMapFromDB(long start, long end, + int targetPID) { Map>> processedResult = new HashMap>>(); String where = "WHERE SAMPLING_TIME BETWEEN " + start + " AND " + end; if (targetPID > 0) { @@ -518,29 +387,7 @@ public class MemoryDataManager extends PageDataManager { return processedResult; } - public List getProcessMemoriesFromDB(long time) { - List processMemories = new ArrayList(); - - String query = "SELECT MEMORY_RESIDENT FROM MEMORY_PROCESS_DATA WHERE SAMPLING_TIME = " - + "(SELECT MAX(SAMPLING_TIME) FROM MEMORY_PROCESS_DATA WHERE SAMPLING_TIME <= " - + time + ")"; - - ResultSet rs = SqlConnectionManager.executeQueryRS(query); - if (rs != null) { - try { - while (rs.next()) { - processMemories.add(rs.getLong(1)); - } - } catch (SQLException e) { - Logger.exception(e); - } finally { - SqlConnectionManager.releaseResultSet(rs); - } - } - return processMemories; - } - - public long getSystemMemoriesFromDB(long time) { + public long getProcessMemoriesFromDB(long time) { long processMemories = 0; String query = "SELECT MEMORY_RESIDENT FROM MEMORY_PROCESS_DATA WHERE SAMPLING_TIME = " + "(SELECT MAX(SAMPLING_TIME) FROM MEMORY_PROCESS_DATA WHERE SAMPLING_TIME <= " @@ -642,4 +489,155 @@ public class MemoryDataManager extends PageDataManager { return allocData; } + + private void GetAllocationData(List memoryLogList) { + int size = memoryLogList.size(); + for (int i = 0; i < size; i++) { + MemoryData logData = (MemoryData) memoryLogList.get(i); + if (allocByteMap.get(logData.getPid()) == null) { + allocByteMap.put(Integer.valueOf(logData.getPid()), new Long(0)); + libraryAllocByteMap.put(Integer.valueOf(logData.getPid()), new HashMap()); + } + + int memApiType = logData.getMemoryApiType(); + int internalFlag = logData.getInternalCall(); + long errorNo = logData.getErrno(); + + /* + * Check library allocation + */ + BinaryInfo binaryInfo = null; + Project project = Global.getProject(); + ProcessMemoryMap pmap = project.getProcessInformation(logData.getPid()).getProcessMemoryMap(logData.getTime()); + + if (pmap != null) { + LibraryObject lib = pmap.getLibraryByAddress(logData.getCallerPcAddr()); + if (lib != null && lib != pmap.getMainbinary()) { + binaryInfo = project.getDeviceStatusInfo().getBinaryInfo(lib.getBinaryID()); + } + } + + if (errorNo == 0 && MEM_USER == internalFlag) { + if (MEM_API_TYPE_ALLOC == memApiType || MEM_API_TYPE_FREE == memApiType) { + addNewSeriesUserAllocData(memApiType, logData, binaryInfo); + } + } + + /* + * Save allocation and free api call + */ + if(MEM_API_TYPE_ALLOC == memApiType) { + makeAllocData(logData); + } + else if(MEM_API_TYPE_FREE == memApiType) { + makeFreeData(logData); + } + } + + } + + private void GetSystemMemoryData(List systemLogList) { + ArrayList> systemDataList = new ArrayList>(); + ArrayList> targetProcessDataList = new ArrayList>(); + + int size = systemLogList.size(); + for (int i = 0; i < size; i++) { + SystemData log = (SystemData) systemLogList.get(i); + + /* + * Make information for other process + */ + List pIDList = new ArrayList(); + List processLoadList = new ArrayList(); + String[] processLoadDatas = log.getOtherProcessLoad().split(CommonConstants.COMMA); + for (int ii = 0; ii < processLoadDatas.length; ii++) { + String processLoad = processLoadDatas[ii]; + if (processLoad == null || processLoad.isEmpty()) { + continue; + } + pIDList.add(new Integer(processLoad)); + processLoadList.add(processLoadDatas[++ii]); + } + + /* + * Make SystemData Table data + */ + ArrayList dbSystemData = new ArrayList(); + dbSystemData.add(new Long(log.getTime())); + dbSystemData.add(new Long(log.getSystemMemoryUsed())); + dbSystemData.add(pIDList); + dbSystemData.add(processLoadList); + systemDataList.add(dbSystemData); + + /* + * Make target Process Table data + */ + ProcessProfileData[] targetProcessList = log.getProcessProfileDataList(); + if (targetProcessList != null) { + for (int j = 0; j < targetProcessList.length; j++) { + ProcessProfileData process = targetProcessList[j]; + + ArrayList dbTargetProcessData = new ArrayList(); + dbTargetProcessData.add(new Long(log.getTime())); + dbTargetProcessData.add(new Integer(process.getPid())); + dbTargetProcessData.add(new Float(process.getProcessLoad())); + dbTargetProcessData.add(new Long(process.getVirtualMemory())); + dbTargetProcessData.add(new Long(process.getResidentMemory())); + dbTargetProcessData.add(new Long(process.getSharedMemory())); + dbTargetProcessData.add(new Long(process.getPssMemory())); + dbTargetProcessData.add(new Integer(process.getThreadCount())); + dbTargetProcessData.add(new Long(process.getTotalAllocSize())); + + /* + * Set inform for Heap allocation + */ + List binaryIDList = new ArrayList(); + List allocByteList = new ArrayList(); + binaryIDList.add(appAllocSeriesID); + if (allocByteMap.get(process.getPid()) == null) { + allocByteList.add(new Long(0)); + } else { + allocByteList.add(allocByteMap.get(process.getPid())); + } + + Map libraryList = libraryAllocByteMap.get(process.getPid()); + if (libraryList == null) { + libraryList = new HashMap(); + } + + Iterator iter = libraryList.keySet().iterator(); + while (iter.hasNext()) { + Integer binaryID = iter.next(); + binaryIDList.add(binaryID); + allocByteList.add(libraryList.get(binaryID)); + } + dbTargetProcessData.add(binaryIDList); + dbTargetProcessData.add(allocByteList); + + /* + * Set inform for Thread + */ + List threadIdList = new ArrayList(); + List threadLoadList = new ArrayList(); + // TODO Remove unnecessary String parsing. first Fix in SystemData.java + String[] threadLoads = process.getThreadLoad().split(CommonConstants.COMMA); + for (int iii = 0; iii < threadLoads.length; iii++) { + String threadLoad = threadLoads[iii]; + if (threadLoad == null || threadLoad.isEmpty()) { + continue; + } + threadIdList.add(new Integer(threadLoad)); + threadLoadList.add(threadLoads[++iii]); + } + dbTargetProcessData.add(threadIdList); + dbTargetProcessData.add(threadLoadList); + + targetProcessDataList.add(dbTargetProcessData); + } + } + } + + systemMemoryDBInserter.pushData(systemDataList); + processMemoryDBInserter.pushData(targetProcessDataList); + } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/ProcessMemoryDBTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/ProcessMemoryDBTable.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/SystemMemoryDBTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/data/SystemMemoryDBTable.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryAllocationTraceTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryAllocationTraceTable.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryDetailsTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryDetailsTable.java old mode 100755 new mode 100644 index b85192b..992244f --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryDetailsTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryDetailsTable.java @@ -58,8 +58,7 @@ public class MemoryDetailsTable extends DATreeComposite { private int keyindex = 0; private Long StartTime; - private Long EndTime; - private Long Current; + private Long EndTime; private String[] columnNames = { MemoryPageLabels.MEMORY_DETAILS_VIEW_ITEM, @@ -82,7 +81,6 @@ public class MemoryDetailsTable extends DATreeComposite { StartTime = (long)0; EndTime = (long)0; - Current = (long) -1; setTableName(MemoryPageLabels.MEMORY_DETAILS_VIEW_TITLE); setComparator(new DefaultTableComparator()); @@ -119,10 +117,9 @@ public class MemoryDetailsTable extends DATreeComposite { }); } - public void setSelectionRange(Long start, Long end, Long current) { + public void setSelectionRange(Long start, Long end) { StartTime = start; EndTime = end; - Current = current; } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryMapTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryMapTable.java old mode 100755 new mode 100644 index 1209973..0178fb5 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryMapTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryMapTable.java @@ -46,20 +46,19 @@ import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; public class MemoryMapTable extends DATableComposite { - private int[] columnSizes = { 40, 60, 150, 80, 80}; - private boolean[] columnVisibility = { true, true, true, true, true }; - private int[] columnAlignment = { SWT.CENTER, SWT.LEFT, SWT.LEFT, SWT.LEFT, SWT.LEFT }; + private int[] columnSizes = { 60, 150, 80, 80}; + private boolean[] columnVisibility = { true, true, true, true }; + private int[] columnAlignment = { SWT.LEFT, SWT.LEFT, SWT.LEFT, SWT.LEFT }; private String[] columnNames = { - MemoryPageLabels.MEMORY_MEMORYMAP_TYPE, MemoryPageLabels.MEMORY_MEMORYMAP_SIZE, MemoryPageLabels.MEMORY_MEMORYMAP_LIBNAME, MemoryPageLabels.MEMORY_MEMORYMAP_ADDRESS_LOW, MemoryPageLabels.MEMORY_MEMORYMAP_ADDRESS_HIGH }; - int[] sortTypes = { AnalyzerConstants.SORT_TYPE_STRING, AnalyzerConstants.SORT_TYPE_NUM, AnalyzerConstants.SORT_TYPE_STRING, - AnalyzerConstants.SORT_TYPE_NUM, AnalyzerConstants.SORT_TYPE_NUM }; + int[] sortTypes = { AnalyzerConstants.SORT_TYPE_NUM, AnalyzerConstants.SORT_TYPE_STRING, AnalyzerConstants.SORT_TYPE_NUM, + AnalyzerConstants.SORT_TYPE_NUM }; public MemoryMapTable(Composite parent, int style, int tableStyle) { super(parent, style, tableStyle); @@ -76,7 +75,7 @@ public class MemoryMapTable extends DATableComposite { setTableToolTipEnable(false); comparator.setType(AnalyzerConstants.SORT_TYPE_NUM); - comparator.setColumn(1); + comparator.setColumn(0); parent.addControlListener(new TableColumnSizePackListener(this, columnSizes)); } @@ -134,11 +133,8 @@ public class MemoryMapTable extends DATableComposite { Long Low = (Long) low; Long High = (Long) high; - Long size = High - Low; - - text.add("r-x-"); - data.add("r-x-"); + Long size = High - Low; text.add(Long.toString(size)); data.add(size); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryStatisticsTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryStatisticsTable.java old mode 100755 new mode 100644 index 0dddc4c..e158175 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryStatisticsTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/memory/table/MemoryStatisticsTable.java @@ -37,7 +37,6 @@ import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.nl.MemoryPageLabels; import org.tizen.dynamicanalyzer.ui.memory.data.AllocateDBTable; -import org.tizen.dynamicanalyzer.ui.memory.data.FreeDBTable; import org.tizen.dynamicanalyzer.ui.memory.data.MemoryDataManager; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; @@ -46,15 +45,15 @@ import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.util.Logger; public class MemoryStatisticsTable extends DATableComposite { - + private int[] columnSizes = { 200 , 100, 80, 80, 100, 80 }; private boolean[] columnVisibility = { true, true, true, true, true, true }; private int[] columnAlignment = { SWT.RIGHT, SWT.RIGHT, SWT.RIGHT, SWT.RIGHT, SWT.RIGHT, SWT.RIGHT }; - + private Long StartTime; - private Long EndTime; - + private Long EndTime; + private String[] columnNames = { MemoryPageLabels.MEMORY_STATISTICS_VIEW_PATH, MemoryPageLabels.MEMORY_STATISTICS_VIEW_PERSISTENT_BYTE, @@ -63,32 +62,27 @@ public class MemoryStatisticsTable extends DATableComposite { MemoryPageLabels.MEMORY_STATISTICS_VIEW_TOTAL_BYTE, MemoryPageLabels.MEMORY_STATISTICS_VIEW_TOTAL }; - + int[] sortTypes = { AnalyzerConstants.SORT_TYPE_STRING, AnalyzerConstants.SORT_TYPE_STRING, AnalyzerConstants.SORT_TYPE_NUM, AnalyzerConstants.SORT_TYPE_NUM, AnalyzerConstants.SORT_TYPE_STRING, AnalyzerConstants.SORT_TYPE_NUM }; - - private final int OUTPUT_PERSISTENT_BYTE = 0; - private final int OUTPUT_PERSISTENT_COUNT = 1; - private final int OUTPUT_FREE_COUNT = 2; - private final int OUTPUT_TOTAL_BYTE = 3; - + public MemoryStatisticsTable(Composite parent, int style, int tableStyle) { super(parent, style, tableStyle); - + StartTime = (long)0; EndTime = (long)0; - + setSortTypes(sortTypes); setColumnAlignment(columnAlignment); setColumns(columnNames); setColumnSize(columnSizes); setColumnVisibility(columnVisibility); - + parent.addControlListener(new TableColumnSizePackListener(this, columnSizes)); } - + public void setSelectionRange(Long start, Long end){ StartTime = start; EndTime = end; @@ -98,40 +92,16 @@ public class MemoryStatisticsTable extends DATableComposite { protected List makeTableInput() { List output = new ArrayList(); List> allocDataList = null; - List> freeDataList = null; - + List> freeDataList = null; + List pidlist = new ArrayList(); + if(Global.getProject() == null) { return output; } - - String pidliststring = getTargetPIDString(); - - allocDataList = MemoryDataManager.getInstance().getAllocationDataFromDB(StartTime, EndTime, pidliststring); - freeDataList = MemoryDataManager.getInstance().getFreeDataFromDB(StartTime, EndTime, pidliststring); - - if (allocDataList == null || freeDataList == null || allocDataList.size() == 0) - return output; - - Map> staticdatas = calculateAllocateData(allocDataList, freeDataList); - - int index = 0; - for(Map.Entry> elem : staticdatas.entrySet()) { - TableInput staticInput = makeTreeInputForDatas(elem.getKey(), elem.getValue(), index++); - - if (staticInput != null){ - output.add(staticInput); - } - } - - return output; - } - - private String getTargetPIDString(){ - List pidlist = new ArrayList(); - + int[] pids = Global.getProject().getProcessIDs(); int targetPID = Toolbar.INSTANCE.getSelectedPid(); - + if(targetPID > 0) { pidlist.add(targetPID); } @@ -140,40 +110,56 @@ public class MemoryStatisticsTable extends DATableComposite { pidlist.add(pids[i]); } } - + String pidliststring = "("; - + for(int i = 0 ; i < pidlist.size() ; i++) { pidliststring += Integer.toString(pidlist.get(i)); - + if(i != pidlist.size() - 1) { pidliststring += ", "; } } - + pidliststring += ")"; + + allocDataList = MemoryDataManager.getInstance().getAllocationDataFromDB(StartTime, EndTime, pidliststring); + freeDataList = MemoryDataManager.getInstance().getFreeDataFromDB(StartTime, EndTime, pidliststring); - return pidliststring; + if (allocDataList == null || freeDataList == null || allocDataList.size() == 0) + return output; + + Map> staticdatas = calculateAllocateData(allocDataList, freeDataList); + + int index = 0; + for(Map.Entry> elem : staticdatas.entrySet()) { + TableInput staticInput = makeTreeInputForDatas(elem.getKey(), elem.getValue(), index++); + + if (staticInput != null){ + output.add(staticInput); + } + } + + return output; } - - @SuppressWarnings("unchecked") + private Map> calculateAllocateData(List> allocData, List> freeData) { // Map for result Map> output = new HashMap> (); - // List for saving allocation address - List addresslist = new ArrayList (); - + // Map for saving allocation address + Map> addresmap = new HashMap> (); + for (int i = 0; i < allocData.size(); i++) { // Get one allocation api data List iAllocData = allocData.get(i); String libname = (String) iAllocData.get(AllocateDBTable.COLUMN.CALLER_LIBRARY_NAME.index); Long address = (Long) iAllocData.get(AllocateDBTable.COLUMN.ALLOCATED_ADDRESS.index); Long size = (Long) iAllocData.get(AllocateDBTable.COLUMN.ALLOCATED_MEMORY_SIZE.index); - + // Save each library to Map if(!output.containsKey(libname)) { List allocdata = new ArrayList(); - + // Persistent Byte allocdata.add(size); // Persistent Count @@ -182,49 +168,40 @@ public class MemoryStatisticsTable extends DATableComposite { allocdata.add((Integer) 0); // Total Byte allocdata.add(size); - + output.put(libname, allocdata); } else { - Long sumsize = (Long)output.get(libname).get(OUTPUT_PERSISTENT_BYTE) + size; - output.get(libname).set(OUTPUT_PERSISTENT_BYTE, sumsize); - output.get(libname).set(OUTPUT_PERSISTENT_COUNT, - (Integer) output.get(libname).get(OUTPUT_PERSISTENT_COUNT) + 1); - output.get(libname).set(OUTPUT_TOTAL_BYTE, sumsize); + Long sumsize = (Long)output.get(libname).get(0) + size; + output.get(libname).set(0, sumsize); + output.get(libname).set(1, (Integer) output.get(libname).get(1) + 1); + output.get(libname).set(3, sumsize); } - + List onedata = new ArrayList (); - onedata.add(address); onedata.add(libname); onedata.add(size); - - addresslist.add(onedata); + + addresmap.put(address, onedata); } - + for (int i = 0; i < freeData.size(); i++) { List iFreeData = freeData.get(i); - long address = (Long) iFreeData.get(FreeDBTable.COLUMN.ALLOCATED_ADDRESS.index); - - for(int j = 0; j < addresslist.size() ; j++) { - if((Long)((List)addresslist.get(j)).get(0) == address) { - List templist = (List)addresslist.get(j); - - String libname = (String) templist.get(1); - Long allocsize = (Long) templist.get(2); - Long persistentsize = (Long) output.get(libname).get(OUTPUT_PERSISTENT_BYTE); - int count = (Integer) output.get(libname).get(OUTPUT_FREE_COUNT); - output.get(libname).set(OUTPUT_PERSISTENT_BYTE, persistentsize - allocsize); - output.get(libname).set(OUTPUT_FREE_COUNT, count + 1); - - addresslist.remove(j); - break; - } + long address = (Long) iFreeData.get(4); + + if(addresmap.containsKey(address)) { + String libname = (String) addresmap.get(address).get(0); + Long allocsize = (Long) addresmap.get(address).get(1); + output.get(libname).set(0, (Long) output.get(libname).get(0) - allocsize); + output.get(libname).set(2, (Integer) output.get(libname).get(2) + 1); + + addresmap.remove(address); } } - + return output; } - + private TableInput makeTreeInputForDatas(String path, List staticdata, int index) { DATableDataFormat tableData = new DATableDataFormat(index); @@ -235,26 +212,27 @@ public class MemoryStatisticsTable extends DATableComposite { Logger.error("very strange case !!"); return null; } - + // Path String libname = path; - + if(path == Global.getCurrentApplication().getMainApp().getExecPath()) { libname = MemoryPageLabels.MEMORY_MAIN_EXCUTABLE; } - + text.add(libname); data.add(libname); + // Persistent byte Long PByte = (Long) staticdata.get(0); data.add(PByte); - + String pbytestr = String.format("%,d B", PByte); if (PByte > 1024) { PByte /= 1024; pbytestr = String.format("%,d KB", PByte); } - + text.add(pbytestr); // Persistent count @@ -270,7 +248,7 @@ public class MemoryStatisticsTable extends DATableComposite { // Total Byte Long TotalByte = (Long) staticdata.get(3); data.add(TotalByte); - + String tbytestr = String.format("%,d B", TotalByte); if (TotalByte > 1024) { TotalByte /= 1024; @@ -282,7 +260,7 @@ public class MemoryStatisticsTable extends DATableComposite { Integer TotalCount = PCount + FCount; text.add(TotalCount.toString()); data.add(TotalCount); - + TreeInput output = new TreeInput(); output.setText(text); tableData.getData().addAll(data); @@ -290,9 +268,9 @@ public class MemoryStatisticsTable extends DATableComposite { return output; } - + public void removeSelection() { table.removeAll(); updateTable(); } -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkChart.java index 8f69265..a2f574b 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkChart.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkChart.java @@ -269,49 +269,55 @@ public class NetworkChart { return; } NetworkSeriesType data = null; - double startTime = -1; - double endTime = -1; for (int i = 0; i < statusList.size(); i++) { - if (!getDestinationAddress().equals(statusList.get(i).getDestinationAddress()) - || !getFdValue().equals(statusList.get(i).getFdValue())) { - continue; - } data = statusList.get(i); if (null == data) { continue; } + if (!getDestinationAddress().equals(data.getDestinationAddress()) + || !getFdValue().equals(data.getFdValue())) { + continue; + } if (isAccessEvent(data.getAPIType())) { continue; } - startTime = getConvertTime(data.getStartTime()); - endTime = getConvertTime(data.getEndTime()); + addStatusItem(data); } + chart.redraw(); + } + + private void addStatusItem(NetworkSeriesType data) { + double startTime = getConvertTime(data.getStartTime()); + double endTime = getConvertTime(data.getEndTime()); + addOpenStatus(startTime); + if (endTime > 0) { + addCloseStatus(endTime); + } + } + + private void addOpenStatus(double startTime){ DAChartSeriesItem seriesItem = new DAChartSeriesItem(startTime, DAChartSeriesItem.SERIES_STATE_CONTINUE, ColorResources.NETWORK_AREA_FD_USED_END, ColorResources.NETWORK_AREA_FD_USED_START, NetworkPageLabels.NETWORK_CHART_TOOLTIP_FD_OPEND); statusSeries.addSeriesItem(seriesItem); - addSeriesItemWhenCloseStatus(endTime, seriesItem); - chart.redraw(); } - private void addSeriesItemWhenCloseStatus(double endTime, DAChartSeriesItem seriesItem) { - if (endTime <= 0) { - return; - } + private void addCloseStatus(double endTime){ + // change the display information of the open status to the close status int nStatusLastIndex = statusSeries.getSeriesItemList().size() - 1; DAChartSeriesItem lastSeriesItem = statusSeries.getSeriesItemList().get(nStatusLastIndex); lastSeriesItem.setColor(ColorResources.NETWORK_AREA_CLOSED_END); lastSeriesItem.setGradationForegroundColor(ColorResources.NETWORK_AREA_CLOSED_START); lastSeriesItem.setTooltipText(NetworkPageLabels.NETWORK_CHART_TOOLTIP_CLOSED); + // in order to stop continue series item, add a new item DAChartSeriesItem endSeriesItem = new DAChartSeriesItem(endTime, - DAChartSeriesItem.SERIES_STATE_BAR, ColorResources.NETWORK_AREA_CLOSED_END, + DAChartSeriesItem.SERIES_STATE_BAR, + ColorResources.NETWORK_AREA_CLOSED_END, ColorResources.NETWORK_AREA_CLOSED_START, NetworkPageLabels.NETWORK_CHART_TOOLTIP_CLOSED); - seriesItem.setBarWidth(0); - statusSeries.addSeriesItem(seriesItem); - lastSeriesItem.setTooltipText(NetworkPageLabels.NETWORK_CHART_TOOLTIP_CLOSED); + endSeriesItem.setBarWidth(0); statusSeries.addSeriesItem(endSeriesItem); } @@ -395,4 +401,4 @@ public class NetworkChart { public void setpId(int pId) { this.pId = pId; } -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTable.java index a59904c..fd21d98 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTable.java @@ -4,6 +4,7 @@ * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved. * * Contact: + * Hyeran Kim * Hyunjong Park * yeongtaik byeon * Juyoung Kim @@ -30,8 +31,8 @@ package org.tizen.dynamicanalyzer.ui.network; import java.util.ArrayList; import java.util.LinkedHashMap; import java.util.List; -import java.util.Map; +import org.eclipse.nebula.widgets.grid.GridColumn; import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; @@ -42,13 +43,15 @@ import org.tizen.dynamicanalyzer.common.Global; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.error.ErrorCodeManager; import org.tizen.dynamicanalyzer.logparser.LogCenterConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; +import org.tizen.dynamicanalyzer.ui.network.data.NetworkAPIDBManager; import org.tizen.dynamicanalyzer.ui.network.data.NetworkDataManager; import org.tizen.dynamicanalyzer.ui.network.data.type.NetworkAPIType; +import org.tizen.dynamicanalyzer.ui.network.data.type.NetworkSelectionType; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; import org.tizen.dynamicanalyzer.ui.widgets.table.DAApiListTableComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableDataFormat; -import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.dynamicanalyzer.utils.Formatter; public class NetworkTable extends DAApiListTableComposite { @@ -89,7 +92,6 @@ public class NetworkTable extends DAApiListTableComposite { @Override public void widgetDefaultSelected(SelectionEvent e) { - // TODO Auto-generated method stub } }); } @@ -97,41 +99,145 @@ public class NetworkTable extends DAApiListTableComposite { @Override protected List makeTableInput() { - NetworkTableView view = (NetworkTableView) AnalyzerManager.getCurrentPage().getView( - NetworkTableView.ID); + NetworkTableView view = (NetworkTableView) AnalyzerManager.getCurrentPage().getView(NetworkTableView.ID); if (null == view) { return null; } - List input = new ArrayList(); - List contentList = NetworkDataManager.getInstance() - .getSelectedTableAPIList(); + List filterList = getFilterPropertyList(); + List contentList = null; + + NetworkSelectionType selectedData = NetworkDataManager.getInstance().getSelectedData(); + if(!filterList.isEmpty()) { // filtering by user + List whereClause = convertFilterProperty2Query(filterList); + contentList = NetworkDataManager + .getInstance() + .getAPIDBManger() + .selectAPITable(selectedData.getAddress(), + selectedData.getFd(), selectedData.isParentChart(), + whereClause); + }else{ + contentList = NetworkDataManager + .getInstance() + .getAPIDBManger() + .selectAPITable(selectedData.getAddress(), + selectedData.getFd(), selectedData.isParentChart(), + null); + + } + if (null == contentList) { return null; } + + List input = new ArrayList(); LinkedHashMap findStartAPITableIndexHashMap = new LinkedHashMap(); - for (int i = 0; i < contentList.size(); i++) { - + LinkedHashMap findStartTimeMap = new LinkedHashMap(); + + contentLoop : for (int i = 0; i < contentList.size(); i++) { NetworkAPIType contentTemp = contentList.get(i); int selectedPid = Toolbar.INSTANCE.getSelectedPid(); if (selectedPid == contentTemp.getPid()) { continue; } - setRemoveAPIIndex(contentTemp, i, findStartAPITableIndexHashMap); + + String elapsedTime = ""; + String strStartTime = ""; + String byteSize = ""; + String apiName = contentTemp.getApiName(); + String argument = contentTemp.getArgs(); + String returnValue = contentTemp.getReturn(); + String payload = getPayload(contentTemp); + String errMessage = getErrorMessage(contentTemp); + + String apiType = Integer.toString(contentTemp.getFdApiType()); + String key = apiEqualsKey(contentTemp); + + if (isStartAPI(apiType)) { + findStartAPITableIndexHashMap.put(key, i); + findStartTimeMap.put(i, contentTemp.getTime()); + continue; + } else if (isEndAPI(apiType)) { + // start time + int startIndex = findStartAPITableIndexHashMap.get(key); + long startTime = findStartTimeMap.get(startIndex); + strStartTime = Formatter.toTimeFormat(startTime); + + // elapsed time + String timeFormat = Formatter.toTimeFormat(contentTemp.getTime() - startTime); + elapsedTime = timeFormat.replace("00:", CommonConstants.EMPTY);//$NON-NLS-1$ + + // messageSize size + byteSize = getMessageSize(contentTemp); + + findStartAPITableIndexHashMap.remove(key); + findStartTimeMap.remove(startIndex); + + } else { + strStartTime = Formatter.toTimeFormat(contentTemp.getTime()); + elapsedTime = "00.000";//$NON-NLS-1$ + } + + for (int j = 0; j < filterList.size(); j++) { + switch(filterList.get(j).getColumnIndex()) { + case 1: // start time + if(!strStartTime.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 2: // elapsedTime + if(!elapsedTime.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 5: // API name + if(!apiName.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 6: // argument + if(!argument.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 7: // return + if(!returnValue.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 8: // message size + if(!byteSize.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 9: // payload + if(!payload.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 10: // errno + if(!errMessage.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + default: + break; + } + } + List contentText = new ArrayList(); + contentText.add(Long.toString(contentTemp.getSeq())); - contentText.add(getStartTime(contentTemp, findStartAPITableIndexHashMap, input)); - contentText - .add(getElaspsedTime(contentTemp, findStartAPITableIndexHashMap, contentList)); + contentText.add(strStartTime); + contentText.add(elapsedTime); contentText.add(Integer.toString(contentTemp.getPid())); contentText.add(Integer.toString(contentTemp.getTid())); contentText.add(contentTemp.getApiName()); contentText.add(contentTemp.getArgs()); - contentText.add(contentTemp.getReturn()); - contentText.add(getMessage(contentTemp)); - contentText.add(getPayload(contentTemp)); - contentText.add(getErrno(contentTemp)); - contentText.add(contentTemp.getReturn()); + contentText.add(returnValue); + contentText.add(byteSize); + contentText.add(payload); + contentText.add(errMessage); DATableDataFormat tableData = new DATableDataFormat(contentTemp.getSeq()); tableData.setLogData(contentTemp); @@ -143,16 +249,38 @@ public class NetworkTable extends DAApiListTableComposite { input.add(tableInput); tableInput.setInRange(setRange(contentTemp, view)); } - removeEndAPI(input, findStartAPITableIndexHashMap); return input; } + + @Override + protected String getFilteredColumnName(int index) { + String columnName = null; + switch(index) { + case 3: + columnName = NetworkAPIDBManager.PID; + break; + case 4: + columnName = NetworkAPIDBManager.TID; + break; + default: + break; + } + return columnName; + } + + public boolean[] getColumnVisibility() { + if (null == table) + return null; + + GridColumn[] columns = table.getColumns(); + int size = columns.length; + boolean[] columnsVisibility = new boolean[size]; - private void setRemoveAPIIndex(NetworkAPIType contentTemp, int tableIndex, - LinkedHashMap findStartAPITableIndexHashMap) { - String fdApiType = Integer.toString(contentTemp.getFdApiType()); - if (isStartAPI(fdApiType)) { - findStartAPITableIndexHashMap.put(apiEqualsKey(contentTemp), tableIndex); + for (int i = 1; i < size; i++) { // except column "#" as index number + columnsVisibility[i] = columns[i].getVisible(); } + + return columnsVisibility; } private boolean isStartAPI(String fdApiType) { @@ -191,51 +319,12 @@ public class NetworkTable extends DAApiListTableComposite { return contentData; } - private String getStartTime(NetworkAPIType contentTemp, - LinkedHashMap findStartAPITableIndexHashMap, List input) { - String fdApiType = Integer.toString(contentTemp.getFdApiType()); - if (isEndAPI(fdApiType)) { - return input.get(getStartAPIIndex(contentTemp, findStartAPITableIndexHashMap)) - .getText().get(NetworkTableView.COLUMN.START_TIME.ordinal()); - } else { - return Formatter.toTimeFormat(contentTemp.getTime()); - } - } - - private String getElaspsedTime(NetworkAPIType contentTemp, - LinkedHashMap findStartAPITableIndexHashMap, - List contentList) { - String fdApiType = Integer.toString(contentTemp.getFdApiType()); - - if (isEndAPI(fdApiType)) { - NetworkAPIType startAPIContentTemp = contentList.get(getStartAPIIndex(contentTemp, - findStartAPITableIndexHashMap)); - long startTime = startAPIContentTemp.getTime(); - String timeFormat = Formatter.toTimeFormat(contentTemp.getTime() - startTime); - String removeTimeFormat = timeFormat.replace("00:", CommonConstants.EMPTY);//$NON-NLS-1$ - return removeTimeFormat; - } else { - return "00.000";//$NON-NLS-1$ - } - } - - private int getStartAPIIndex(NetworkAPIType contentTemp, - LinkedHashMap findStartAPITableIndexHashMap) { - Integer startLogIndex = findStartAPITableIndexHashMap.get(apiEqualsKey(contentTemp)); - if (null == startLogIndex) { - Logger.error("not exist network start api index"); - return 0; - } else { - return startLogIndex; - } - } - private String apiEqualsKey(NetworkAPIType contentTemp) { return Global.getFunctionName(contentTemp.getApiId()) + contentTemp.getPid() + contentTemp.getTid(); } - private String getMessage(NetworkAPIType contentTemp) { + private String getMessageSize(NetworkAPIType contentTemp) { int apiType = contentTemp.getFdApiType(); if (apiType == LogCenterConstants.SOCKET_API_SEND_END || apiType == LogCenterConstants.SOCKET_API_RECV_END @@ -256,7 +345,7 @@ public class NetworkTable extends DAApiListTableComposite { return payloadInfo.toString(); } - private String getErrno(NetworkAPIType contentTemp) { + private String getErrorMessage(NetworkAPIType contentTemp) { String errMsg = ErrorCodeManager.getInatance().getErrorCode( Long.toString(contentTemp.getErrno())); if (null == errMsg) { @@ -266,7 +355,7 @@ public class NetworkTable extends DAApiListTableComposite { } private boolean setFailed(NetworkAPIType contentTemp) { - if (!getErrno(contentTemp).contains("SUCCESS")) {//$NON-NLS-1$ + if (!getErrorMessage(contentTemp).contains("SUCCESS")) {//$NON-NLS-1$ return true; } else { return false; @@ -283,18 +372,4 @@ public class NetworkTable extends DAApiListTableComposite { return false; } } - - private void removeEndAPI(List input, - LinkedHashMap findStartAPITableIndexHashMap) { - int removeCount = 0; - for (Map.Entry entry : findStartAPITableIndexHashMap.entrySet()) { - int removeIndex = entry.getValue() - removeCount; - if (input.size() <= removeIndex) { - Logger.error("not exist network remove start api index"); - return; - } - input.remove(removeIndex); - removeCount++; - } - } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTableView.java index 2a55f46..2a6c1a9 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/NetworkTableView.java @@ -39,18 +39,19 @@ import org.tizen.dynamicanalyzer.ui.network.data.NetworkDataManager; import org.tizen.dynamicanalyzer.ui.network.data.type.NetworkSelectionType; import org.tizen.dynamicanalyzer.ui.range.RangeDataManager; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.util.Logger; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class NetworkTableView extends DAViewComposite { +public class NetworkTableView extends DAAdvancedViewComposite { public static final String ID = NetworkTableView.class.getName(); private long preAnalysisStartTime = 0; private long preAnalysisEndTime = 0; private boolean isChangedSelected = true; private int preSelectionPId = 1; + NetworkSelectionType netSelection = null; public enum COLUMN { INDEX(0, NetworkPageLabels.NETWORK_API_LIST_VIEW_INDEX), START_TIME(1, @@ -99,7 +100,7 @@ public class NetworkTableView extends DAViewComposite { NetworkTable tableComp = null; public NetworkTableView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(NetworkPageLabels.NETWORK_API_LIST_VIEW_TITLE); @@ -115,20 +116,17 @@ public class NetworkTableView extends DAViewComposite { tableComp.setColumnSize(columnSizes); tableComp.setTableName(NetworkPageLabels.NETWORK_API_LIST_VIEW_TITLE); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } @Override public void updateView() { - try { - if (null == tableComp) { - return; - } + if (null == tableComp || netSelection == null) { + return; + } - if (isUpdateTable()) { - tableComp.updateTable(); - } - } catch (Exception e) { - Logger.error("exception network updateView"); + if (isUpdateTable()) { + tableComp.updateTable(); } } @@ -176,16 +174,16 @@ public class NetworkTableView extends DAViewComposite { return; } - NetworkSelectionType netSelection = (NetworkSelectionType) selData.getData(); + netSelection = (NetworkSelectionType) selData.getData(); if (null == netSelection) { return; } + + NetworkDataManager.getInstance().setSelectedData(netSelection); NetworkDataManager.getInstance().setSelectedTableAPIList( - NetworkDataManager - .getInstance() - .getAPIDBManger() - .selectAPITable(netSelection.getAddress(), netSelection.getFd(), - netSelection.isParentChart())); + NetworkDataManager.getInstance().getAPIDBManger().selectAPITable( + netSelection.getAddress(), netSelection.getFd(), netSelection.isParentChart(), null)); + tableComp.updateTable(); tableComp.setSelectionByTime(selectionStartTime, selectionEndTime); isChangedSelected = true; @@ -203,6 +201,7 @@ public class NetworkTableView extends DAViewComposite { @Override public void clear() { tableComp.getTable().removeAll(); + netSelection = null; } public long getRangeStartTime() { diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkAPIDBManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkAPIDBManager.java index 140722c..f7e2be7 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkAPIDBManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkAPIDBManager.java @@ -163,12 +163,21 @@ public class NetworkAPIDBManager extends DBTable { return returnValue; } - public List selectAPITable(String address, String fd, boolean isParentChart) { - String query = String.format(SELECT_API_TABLE_CHILD_QUERY, address.trim(), fd.trim()); + public List selectAPITable(String address, String fd, boolean isParentChart, + List whereClause) { + String query = null; if (isParentChart) { query = String.format(SELECT_API_TABLE_PARENT_QUERY, address.trim()); + }else{ + query = String.format(SELECT_API_TABLE_CHILD_QUERY, address.trim(), fd.trim()); } - + + if( whereClause != null && whereClause.size() > 0) { + for(int i =0; i < whereClause.size(); i++) { + query += " and " + whereClause.get(i); + } + } + ResultSet rs = SqlConnectionManager.executeQueryRS(query); if (rs == null) { SqlConnectionManager.releaseResultSet(rs); @@ -201,7 +210,7 @@ public class NetworkAPIDBManager extends DBTable { } return returnValue; } - + @Override public boolean prepare(PreparedStatement prep, List rowData) { boolean isPrepared = true; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkDataManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkDataManager.java index 02d78ee..b3f5f6c 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkDataManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/network/data/NetworkDataManager.java @@ -39,6 +39,7 @@ import org.tizen.dynamicanalyzer.swap.logparser.Logs; import org.tizen.dynamicanalyzer.swap.logparser.PageDataManager; import org.tizen.dynamicanalyzer.swap.model.data.LogData; import org.tizen.dynamicanalyzer.ui.network.data.type.NetworkAPIType; +import org.tizen.dynamicanalyzer.ui.network.data.type.NetworkSelectionType; import org.tizen.dynamicanalyzer.ui.network.data.type.NetworkSeriesType; public class NetworkDataManager extends PageDataManager { @@ -66,6 +67,8 @@ public class NetworkDataManager extends PageDataManager { private List seriesList = new ArrayList(); private LinkedHashMap parentChartIndexOfSeq = new LinkedHashMap(); private LinkedHashMap childChartIndexOfSeq = new LinkedHashMap(); + + NetworkSelectionType selectedData = null; private int chartCount = 0; private int accessSeriesSize = 0; @@ -168,6 +171,15 @@ public class NetworkDataManager extends PageDataManager { public void setSelectedTableAPIList(List selectedTableAPIList) { this.selectedTableAPIList = selectedTableAPIList; } + + public void setSelectedData(NetworkSelectionType selectedData) { + this.selectedData = selectedData; + } + + public NetworkSelectionType getSelectedData() { + return selectedData; + } + private void checkHeapMemory() { double useHeapMemory = (chartCount * ONE_CHART_HEAP_MEMORY_KB) diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/GLPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/GLPage.java old mode 100755 new mode 100644 index b7a422a..b652d69 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/GLPage.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/GLPage.java @@ -44,6 +44,7 @@ import org.tizen.dynamicanalyzer.ui.opengl.table.state.GLRedundantTableView; import org.tizen.dynamicanalyzer.ui.opengl.table.state.GLStatisticsTableView; import org.tizen.dynamicanalyzer.ui.opengl.table.state.GLTextureTableView; import org.tizen.dynamicanalyzer.ui.page.ScreenshotTabComposite; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedTabComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAPageComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DATabComposite; import org.tizen.dynamicanalyzer.resources.ColorResources; @@ -61,7 +62,9 @@ public class GLPage extends DAPageComposite { public static final String textureViewID = GLTextureTableView.class.getName(); public static final String statisticsViewID = GLStatisticsTableView.class.getName(); public static final String redundantViewID = GLRedundantTableView.class.getName(); - public static final int RIGHT_TAB_BUTTON_WIDTH = 92; + + public static final int RIGHT_TAB_WIDTH = 97; + SashForm baseForm; SashForm rightForm; SashForm leftForm; @@ -88,16 +91,17 @@ public class GLPage extends DAPageComposite { baseForm.setForeground(ColorResources.TAB_SELECTED_COLOR_START); ((FillLayout) getLayout()).marginHeight = 15; ((FillLayout) getLayout()).marginWidth = 5; - + leftForm = new SashForm(baseForm, SWT.VERTICAL); glChartView = new GLChartView(leftForm, SWT.NONE); addView(glChartView); - bottomForm = new SashForm(leftForm, SWT.HORIZONTAL); + + bottomForm = new SashForm(leftForm, SWT.HORIZONTAL); bottomForm.setForeground(ColorResources.TAB_SELECTED_COLOR_START); bottomForm.setLayout(new FillLayout()); - - DATabComposite glLeftTabView = new DATabComposite(bottomForm, SWT.NONE, false); + + DATabComposite glLeftTabView = new DAAdvancedTabComposite(bottomForm, SWT.NONE, false); { glStatisticsView = new GLStatisticsTableView(glLeftTabView.getContentComposite(), SWT.NONE); @@ -109,8 +113,10 @@ public class GLPage extends DAPageComposite { glLeftTabView.addView(glAPIListView, false); } - DATabComposite glRightTabView = new DATabComposite(bottomForm, SWT.NONE, false); - glRightTabView.setTabWidth(RIGHT_TAB_BUTTON_WIDTH); + + DATabComposite glRightTabView = new DAAdvancedTabComposite(bottomForm, SWT.NONE, false); + glRightTabView.setTabWidth(RIGHT_TAB_WIDTH); + { glRedundantView = new GLRedundantTableView(glRightTabView.getContentComposite(), SWT.NONE); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/chart/GLChartView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/chart/GLChartView.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/DB/GLAPIDBTableManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/DB/GLAPIDBTableManager.java index 86e1255..c8d9372 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/DB/GLAPIDBTableManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/DB/GLAPIDBTableManager.java @@ -43,19 +43,19 @@ import org.tizen.dynamicanalyzer.util.Logger; public class GLAPIDBTableManager extends DBTable { public static final String TABLENAME = "GL_API";//$NON-NLS-1$ - private static final String SEQ = "SEQUENCE_NUMBER"; //$NON-NLS-1$ - private static final String FRAME_INDEX = "FRAME_INDEX";//$NON-NLS-1$ - private static final String CONTEXT_ID = "CONTEXT_ID";//$NON-NLS-1$ - private static final String TIME = "SATRT_TIME"; //$NON-NLS-1$ - private static final String API_ID = "API_ID"; //$NON-NLS-1$ - private static final String ARGUMENT = "ARGUMENT"; //$NON-NLS-1$ - private static final String RET = "RETURN_VALUE"; //$NON-NLS-1$ - private static final String ELAPSED_TIME = "ELAPSED_TIME";//$NON-NLS-1$ - private static final String ERROR = "ERROR_NUMBER"; //$NON-NLS-1$ - private static final String PID = "PID"; //$NON-NLS-1$ - private static final String TID = "TID"; //$NON-NLS-1$ - private static final String CALLER_PC_ADDRESS = "CALLER_PC_ADDRESS"; //$NON-NLS-1$ - private static final String LIB_NAME = "CALLER_LIBRARY_NAME"; //$NON-NLS-1$ + public static final String SEQ = "SEQUENCE_NUMBER"; //$NON-NLS-1$ + public static final String FRAME_INDEX = "FRAME_INDEX";//$NON-NLS-1$ + public static final String CONTEXT_ID = "CONTEXT_ID";//$NON-NLS-1$ + public static final String TIME = "SATRT_TIME"; //$NON-NLS-1$ + public static final String API_ID = "API_ID"; //$NON-NLS-1$ + public static final String ARGUMENT = "ARGUMENT"; //$NON-NLS-1$ + public static final String RET = "RETURN_VALUE"; //$NON-NLS-1$ + public static final String ELAPSED_TIME = "ELAPSED_TIME";//$NON-NLS-1$ + public static final String ERROR = "ERROR_NUMBER"; //$NON-NLS-1$ + public static final String PID = "PID"; //$NON-NLS-1$ + public static final String TID = "TID"; //$NON-NLS-1$ + public static final String CALLER_PC_ADDRESS = "CALLER_PC_ADDRESS"; //$NON-NLS-1$ + public static final String LIB_NAME = "CALLER_LIBRARY_NAME"; //$NON-NLS-1$ public final static int TABLE_SEQ_INDEX = 0; public final static int TABLE_CONTEXT_ID_INDEX = 1; @@ -117,9 +117,14 @@ public class GLAPIDBTableManager extends DBTable { insertData(insertDataList); } - public List selectOpenGLAPIData(int frameStartIndex, int frameEndIndex) { + public List selectOpenGLAPIData(int frameStartIndex, int frameEndIndex, List whereClause) { String query = String.format(SELECT_API_TABLE_QUERY_FROM_FRAME_RATE_CHART, frameStartIndex, frameEndIndex); + if(whereClause != null) { + for(int i = 0; i < whereClause.size(); i++) { + query += " and " + whereClause.get(i); + } + } ResultSet rs = SqlConnectionManager.executeQueryRS(query); if (rs == null) { SqlConnectionManager.releaseResultSet(rs); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/GLDataManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/GLDataManager.java index 31be450..2967e60 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/GLDataManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/data/GLDataManager.java @@ -340,15 +340,12 @@ public class GLDataManager extends PageDataManager { this.selectedContextID = selectedContextID; } - public List getCurrentAPITableData(int frameStartIndex, int frameEndIndex) { - if (currentAPITableData != null && chartSelectedStartIndexForAPITable == frameStartIndex - && chartSelectedEndIndexForAPITable == frameEndIndex) { - return currentAPITableData; - } + public List getCurrentAPITableData(int frameStartIndex, int frameEndIndex, List whereClause) { chartSelectedStartIndexForAPITable = frameStartIndex; chartSelectedEndIndexForAPITable = frameEndIndex; + currentAPITableData = getAPIDataMagerInstance().selectOpenGLAPIData(frameStartIndex, - frameEndIndex); + frameEndIndex, whereClause) ; return currentAPITableData; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPIListView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPIListView.java old mode 100755 new mode 100644 index 9f8c8a4..33e4b3e --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPIListView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPIListView.java @@ -42,12 +42,13 @@ import org.tizen.dynamicanalyzer.ui.opengl.data.GLDataManager; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLFrameRateInfo; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLSelectionData; import org.tizen.dynamicanalyzer.ui.timeline.common.TimelineConstants; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class GLAPIListView extends DAViewComposite { +public class GLAPIListView extends DAAdvancedViewComposite { GLAPITable glAPIListTable; private String[] columnNames = { GLPageLabels.GL_API_LIST_VIEW_SEQ, @@ -72,7 +73,8 @@ public class GLAPIListView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_NUM, }; public GLAPIListView(Composite parent, int style) { - super(parent, style, false); + super(parent, style, false, false); + setLayout(new FillLayout()); setTitle(GLPageLabels.GL_API_LIST_VIEW_TITLE); Composite contents = getContentArea(); @@ -90,6 +92,7 @@ public class GLAPIListView extends DAViewComposite { glAPIListTable.setTableToolTipEnable(true); contents.addControlListener(new TableColumnSizePackListener(glAPIListTable, columnSizes)); + setTable(glAPIListTable); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPITable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPITable.java index e8a4ada..f427f10 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPITable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/api/GLAPITable.java @@ -30,16 +30,20 @@ import java.util.ArrayList; import java.util.List; import org.eclipse.nebula.widgets.grid.Grid; +import org.eclipse.nebula.widgets.grid.GridColumn; import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; +import org.tizen.dynamicanalyzer.common.Global; import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; import org.tizen.dynamicanalyzer.ui.opengl.data.GLDataManager; +import org.tizen.dynamicanalyzer.ui.opengl.data.DB.GLAPIDBTableManager; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLAPIData; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLConstantDefine; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLES20ErrorDefine; @@ -87,27 +91,75 @@ public class GLAPITable extends DATableComposite { protected List makeTableInput() { List input = new ArrayList(); - List apiList = GLDataManager.getInstance().getCurrentAPITableData( - startFrameIndex, endFrameIndex); + List apiList = null; + List filterList = getFilterPropertyList(); + + if(!filterList.isEmpty()) { // filtering by user + List whereClause = convertFilterProperty2Query(filterList); + apiList = GLDataManager.getInstance().getCurrentAPITableData( + startFrameIndex, endFrameIndex, whereClause); + }else{ + apiList = GLDataManager.getInstance().getCurrentAPITableData( + startFrameIndex, endFrameIndex, null); + } + if (null == apiList) { return null; } int size = apiList.size(); - for (int i = 0; i < size; i++) { + contentLoop : for (int i = 0; i < size; i++) { GLAPIData glApiType = apiList.get(i); String seq = Long.toString(glApiType.getSeq()); + String apiName = glApiType.getApiName(); + String time = String.valueOf(Formatter.toTimeFormat(glApiType.getTime())); + String args = GLConstantDefine.convertEnumValue(glApiType.getArgs(), CommonConstants.COMMA, null); + String elapsedTime = String.valueOf(glApiType.getElapsedTime()); + String errMsg = GLES20ErrorDefine.getError(glApiType.getErrno()); + + + for (int j = 0; j < filterList.size(); j++) { + switch(filterList.get(j).getColumnIndex()) { + case 2: // start time + if(!time.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 3: // api name + if(!apiName.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 4: // args + if(!args.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 6: // elapsed time + if(!elapsedTime.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 7: // errMsg + if(!errMsg.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + default: + break; + } + } + List text = new ArrayList(); text.add(seq); text.add(Integer.toString(glApiType.getFrameIndex())); - text.add(String.valueOf(Formatter.toTimeFormat(glApiType.getTime()))); - text.add(glApiType.getApiName()); - text.add(GLConstantDefine.convertEnumValue(glApiType.getArgs(), CommonConstants.COMMA, - null)); + text.add(time); + text.add(apiName); + text.add(args); text.add(glApiType.getReturn()); - text.add(String.valueOf(glApiType.getElapsedTime())); - text.add(GLES20ErrorDefine.getError(glApiType.getErrno())); + text.add(elapsedTime); + text.add(errMsg); text.add(String.valueOf(glApiType.getPid())); text.add(String.valueOf(glApiType.getTid())); @@ -134,6 +186,28 @@ public class GLAPITable extends DATableComposite { return input; } + @Override + protected String getFilteredColumnName(int index) { + String columnName = null; + switch(index) { + case 1: // frame; + columnName = GLAPIDBTableManager.FRAME_INDEX; + break; + case 5: // return; + columnName = GLAPIDBTableManager.RET; + break; + case 8: // pid + columnName = GLAPIDBTableManager.PID; + break; + case 9: // tid + columnName = GLAPIDBTableManager.TID; + break; + default: + break; + } + return columnName; + } + public void removeSelection() { table.removeAll(); updateTable(); @@ -203,4 +277,19 @@ public class GLAPITable extends DATableComposite { output = (output < 0) ? 0 : output; return output; } + + public boolean[] getColumnVisibility() { + if (null == table) + return null; + + GridColumn[] columns = table.getColumns(); + int size = columns.length; + boolean[] columnsVisibility = new boolean[size]; + + for (int i = 1; i < size; i++) { + columnsVisibility[i] = columns[i].getVisible(); + } + + return columnsVisibility; + } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTable.java index a59b9d3..6841cd8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTable.java @@ -46,6 +46,7 @@ import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.resources.ImageResources; @@ -387,5 +388,4 @@ public class GLContextTable extends DATableComposite { AnalyzerManager.getCurrentPage().updateView(selData); disposeNaviButtons(); } - } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTableView.java old mode 100755 new mode 100644 index 8168a9e..1c5d089 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLContextTableView.java @@ -53,12 +53,13 @@ import org.tizen.dynamicanalyzer.ui.opengl.data.GLDataManager; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLAPIData; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLContextNameEnum; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLSelectionData; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedPopupMenu.ADVANCED_MENU_ITEM; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableDataFormat; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class GLContextTableView extends DAViewComposite { +public class GLContextTableView extends DAAdvancedViewComposite { GLContextTable tableComp = null; private Canvas titleBar = null; private int[] columnSizes = { 150, 100, 400 }; @@ -78,7 +79,8 @@ public class GLContextTableView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_STRING }; public GLContextTableView(Composite parent, int style) { - super(parent, style, false); + super(parent, style, false, false); + this.setLayout(new FillLayout()); setTitle(GLPageLabels.GL_CONTEXT_VIEW_TITLE); @@ -99,6 +101,9 @@ public class GLContextTableView extends DAViewComposite { tableComp.setColumnVisibility(columnVisibility); tableComp.setTableToolTipEnable(false); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); + // disable filter menu + disableAdvancedMenuItem(ADVANCED_MENU_ITEM.FILTER.index); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTable.java index b54d00a..f808eb9 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTable.java @@ -35,6 +35,7 @@ import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.GLPageLabels; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; @@ -73,16 +74,18 @@ public class GLProgramTable extends DATableComposite { if(null == GLDataManager.getInstance().getStateDataManager()){ return input; } + + List filterList = getFilterPropertyList(); + List programList = GLDataManager.getInstance().getStateDataManager() - .getProgramMakeObject().getProgramList(); + .getProgramMakeObject().getProgramList(); int size = 0; if (null != programList) { size = programList.size(); } - for (int i = 0; i < size; i++) { - List text = new ArrayList(); + contentLoop : for (int i = 0; i < size; i++) { String programId = Integer.toString(programList.get(i).getId()); DATableDataFormat tableData = new DATableDataFormat(Long.parseLong(programId)); @@ -91,7 +94,35 @@ public class GLProgramTable extends DATableComposite { String vertexShaderID = GLPageLabels.GL_SHADER + programList.get(i).getVertexShaderId(); String vertexFragmentID = GLPageLabels.GL_SHADER + programList.get(i).getFragmentShaderId(); + + for (int j = 0; j < filterList.size(); j++) { + switch(filterList.get(j).getColumnIndex()) { + case 0: // programID + if(!programID.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 1: // contextName + if(!contextName.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 2: // shaderId + if(!vertexShaderID.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 3: // fragmentId + if(!vertexFragmentID.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + default: + break; + } + } + List text = new ArrayList(); text.add(programID); text.add(contextName); text.add(vertexShaderID); @@ -113,7 +144,7 @@ public class GLProgramTable extends DATableComposite { } return input; } - + public void removeSelection() { table.removeAll(); updateTable(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTableView.java old mode 100755 new mode 100644 index 0857817..8167787 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLProgramTableView.java @@ -36,12 +36,13 @@ import org.tizen.dynamicanalyzer.nl.GLPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLSelectionData; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class GLProgramTableView extends DAViewComposite { +public class GLProgramTableView extends DAAdvancedViewComposite { GLProgramTable tableComp = null; private int[] columnSizes = { 90, 90, 110, 110 }; private boolean[] columnVisibility = { true, true, true, true }; @@ -57,7 +58,8 @@ public class GLProgramTableView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_GRID, AnalyzerConstants.SORT_TYPE_GRID }; public GLProgramTableView(Composite parent, int style) { - super(parent, style, false); + super(parent, style, false, false); + this.setLayout(new FillLayout()); setTitle(GLPageLabels.GL_PROGRAMS_VIEW_TITLE); @@ -77,6 +79,7 @@ public class GLProgramTableView extends DAViewComposite { tableComp.setTableToolTipEnable(false); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTable.java index 32f3dc3..7877252 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTable.java @@ -36,6 +36,7 @@ import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; import org.tizen.dynamicanalyzer.ui.opengl.data.GLDataManager; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTableView.java old mode 100755 new mode 100644 index 4b36e14..b17962d --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLRedundantTableView.java @@ -35,12 +35,13 @@ import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.nl.GLPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLSelectionData; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedPopupMenu.ADVANCED_MENU_ITEM; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class GLRedundantTableView extends DAViewComposite { +public class GLRedundantTableView extends DAAdvancedViewComposite { public static final int COUNT_TABLE_INDEX = 0; public static final int ELAPSED_TIME_TABLE_INDEX = 1; public static final int API_NAME_TABLE_INDEX = 2; @@ -58,7 +59,8 @@ public class GLRedundantTableView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_STRING, AnalyzerConstants.SORT_TYPE_STRING }; public GLRedundantTableView(Composite parent, int style) { - super(parent, style, false); + super(parent, style, false, false); + this.setLayout(new FillLayout()); setTitle(GLPageLabels.GL_REDUNDANT_TITLE); Composite contents = getContentArea(); @@ -75,6 +77,9 @@ public class GLRedundantTableView extends DAViewComposite { tableComp.setColumnVisibility(columnVisibility); tableComp.setTableToolTipEnable(false); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); + // disable filter menu + disableAdvancedMenuItem(ADVANCED_MENU_ITEM.FILTER.index); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTable.java index 66f8f65..57cb918 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTable.java @@ -36,6 +36,7 @@ import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; import org.tizen.dynamicanalyzer.ui.opengl.data.GLDataManager; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTableView.java old mode 100755 new mode 100644 index 2673d14..4feedd8 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLStatisticsTableView.java @@ -35,12 +35,13 @@ import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.nl.GLPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLSelectionData; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedPopupMenu.ADVANCED_MENU_ITEM; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class GLStatisticsTableView extends DAViewComposite { +public class GLStatisticsTableView extends DAAdvancedViewComposite { public static final int API_NAME_TABLE_INDEX = 0; public static final int TABLE_RATE_TABLE_INDEX = 1; public static final int COUNT_TABLE_INDEX = 2; @@ -59,7 +60,8 @@ public class GLStatisticsTableView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_NUM, AnalyzerConstants.SORT_TYPE_STRING }; public GLStatisticsTableView(Composite parent, int style) { - super(parent, style, false); + super(parent, style, false, false); + this.setLayout(new FillLayout()); setTitle(GLPageLabels.GL_STATISTICS_TITLE); Composite contents = getContentArea(); @@ -76,6 +78,9 @@ public class GLStatisticsTableView extends DAViewComposite { tableComp.setColumnVisibility(columnVisibility); tableComp.setTableToolTipEnable(false); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); + // disable filter menu + disableAdvancedMenuItem(ADVANCED_MENU_ITEM.FILTER.index); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTable.java index 329c5a1..cec0703 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTable.java @@ -35,6 +35,7 @@ import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.GLPageLabels; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; @@ -83,21 +84,71 @@ public class GLTextureTable extends DATableComposite { } int size = textureList.size(); - for (int i = 0; i < size; i++) { - List text = new ArrayList(); - + contentLoop : for (int i = 0; i < size; i++) { + List filterList = getFilterPropertyList(); + String textureId = Integer.toString(textureList.get(i).getObjID()); DATableDataFormat tableData = new DATableDataFormat(Long.parseLong(textureId)); + + String contextId = GLPageLabels.GL_CONTEXT + Long.toString(textureList.get(i).getContextID()); + String textureIdStr = GLPageLabels.GL_TEXTURE + textureId; + String type = GLConstantDefine.getConstantString(textureList.get(i).getType()); + String wrapS = GLConstantDefine.getConstantString(textureList.get(i).getWrapS()); + String wrapT = GLConstantDefine.getConstantString(textureList.get(i).getWrapT()); + String minFilter = GLConstantDefine.getConstantString(textureList.get(i).getMinFilter()); + String magFilter = GLConstantDefine.getConstantString(textureList.get(i).getMagFilter()); + + for (int j = 0; j < filterList.size(); j++) { + switch(filterList.get(j).getColumnIndex()) { + case 0: + if(!contextId.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 1: + if(!textureIdStr.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 2: + if(!type.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 3: + if(!wrapS.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 4: + if(!wrapT.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 5: + if(!minFilter.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + case 6: + if(!magFilter.toLowerCase().contains(filterList.get(j).getKeyWord().toLowerCase())) { + continue contentLoop; + } + break; + default: + break; + } + } - text.add(GLPageLabels.GL_CONTEXT + Long.toString(textureList.get(i).getContextID())); - text.add(GLPageLabels.GL_TEXTURE + textureId); - - text.add(GLConstantDefine.getConstantString(textureList.get(i).getType())); - text.add(GLConstantDefine.getConstantString(textureList.get(i).getWrapS())); - text.add(GLConstantDefine.getConstantString(textureList.get(i).getWrapT())); - text.add(GLConstantDefine.getConstantString(textureList.get(i).getMinFilter())); - text.add(GLConstantDefine.getConstantString(textureList.get(i).getMagFilter())); + List text = new ArrayList(); + text.add(contextId); + text.add(textureIdStr); + text.add(type); + text.add(wrapS); + text.add(wrapT); + text.add(minFilter); + text.add(magFilter); TableInput tableInput = new TableInput(); tableInput.setText(text); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTableView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTableView.java old mode 100755 new mode 100644 index cf1064a..048fa8f --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTableView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/opengl/table/state/GLTextureTableView.java @@ -36,12 +36,13 @@ import org.tizen.dynamicanalyzer.nl.GLPageLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.opengl.GLPage; import org.tizen.dynamicanalyzer.ui.opengl.data.type.GLSelectionData; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class GLTextureTableView extends DAViewComposite { +public class GLTextureTableView extends DAAdvancedViewComposite { GLTextureTable tableComp = null; private int[] columnSizes = { 80, 80, 110, 120, 120, 100, 100 }; private boolean[] columnVisibility = { true, true, true, true, true, true, true }; @@ -61,7 +62,7 @@ public class GLTextureTableView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_GRID }; public GLTextureTableView(Composite parent, int style) { - super(parent, style, false); + super(parent, style, false, false); this.setLayout(new FillLayout()); setTitle(GLPageLabels.GL_TEXTURE_VIEW_TITLE); @@ -81,6 +82,7 @@ public class GLTextureTableView extends DAViewComposite { tableComp.setTableToolTipEnable(false); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/BaseView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/BaseView.java old mode 100755 new mode 100644 index 193c419..4365edd --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/BaseView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/BaseView.java @@ -27,6 +27,7 @@ package org.tizen.dynamicanalyzer.ui.page; +import java.io.File; import java.util.ArrayList; import java.util.List; import java.util.Set; @@ -34,11 +35,24 @@ import java.util.Set; import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Display; +import org.eclipse.swt.widgets.Shell; import org.eclipse.ui.part.ViewPart; import org.tizen.dynamicanalyzer.annotation.UIMethod; +import org.tizen.dynamicanalyzer.callback.ExecutionCallbackManager; +import org.tizen.dynamicanalyzer.common.AnalyzerManager; +import org.tizen.dynamicanalyzer.common.DAState; +import org.tizen.dynamicanalyzer.common.PostWindowOpenCallback; +import org.tizen.dynamicanalyzer.common.PreWindowShellCloseCallback; +import org.tizen.dynamicanalyzer.common.path.PathManager; +import org.tizen.dynamicanalyzer.communicator.DeviceManager; +import org.tizen.dynamicanalyzer.communicator.IDECommunicator; +import org.tizen.dynamicanalyzer.control.SideWorker; +import org.tizen.dynamicanalyzer.database.SqlConnectionManager; +import org.tizen.dynamicanalyzer.handlers.ExitHandler; import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.setting.SettingConstants; import org.tizen.dynamicanalyzer.setting.SettingDataManager; +import org.tizen.dynamicanalyzer.swap.platform.BinarySettingManager; import org.tizen.dynamicanalyzer.ui.file.FilePage; import org.tizen.dynamicanalyzer.ui.hierarchy.HierarchyPage; import org.tizen.dynamicanalyzer.ui.interactive.InteractivePage; @@ -51,14 +65,19 @@ import org.tizen.dynamicanalyzer.ui.summary.SummaryPage; import org.tizen.dynamicanalyzer.ui.thread.ThreadPage; import org.tizen.dynamicanalyzer.ui.timeline.TimelinePage; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; +import org.tizen.dynamicanalyzer.ui.toolbar.setting.SettingDialog; import org.tizen.dynamicanalyzer.ui.userinterface.UIPage; import org.tizen.dynamicanalyzer.util.Logger; +import org.tizen.dynamicanalyzer.util.WorkbenchUtil; +import org.tizen.dynamicanalyzer.utils.AnalyzerUtil; import org.tizen.dynamicanalyzer.widgets.da.view.DABaseComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAPageComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DATabComposite; import org.tizen.dynamicanalyzer.workbench.LayoutManager; public class BaseView extends ViewPart { + public BaseView() { + } public static final String ID = BaseView.class.getName(); private static final String[] pageOrder = { SettingConstants.PAGE_NAME_TIME_LINE, @@ -75,17 +94,80 @@ public class BaseView extends ViewPart { @Override public void createPartControl(Composite parent) { // create toolbar + Composite newParent = LayoutManager.createComposite(parent); Composite toolbarComposite = LayoutManager.getToolbarComposite(); Toolbar.INSTANCE.create(toolbarComposite); - // create tab view in base composite - tabView = new DATabComposite(parent, SWT.DOUBLE_BUFFERED); + // create tab view in composite + tabView = new DATabComposite(newParent, SWT.DOUBLE_BUFFERED); tabView.setTabWidth(114); tabView.isImageTab(false); tabView.setTabBGColor(ColorResources.TAB_BG_COLOR , ColorResources.TAB_BG_COLOR ); createPagesByTarget(null); + RunInitializing(); } + + public void RunInitializing(){ + // check Tizen SDK path and Platform DA checking + AnalyzerManager.setPlatformSDK(PathManager.checkPlatformPlugin()); + DAState.changeCurrentState(DAState.INIT); + SettingDataManager setting = SettingDataManager.INSTANCE; + + // initialize device connection + DeviceManager.init(); + DeviceManager.addDeviceListener(); + + Thread deviceinitthread = new Thread(new Runnable() { + public void run() { + DeviceManager.loadDevices(); + + Display.getDefault().asyncExec(new Runnable() { + public void run() { + // initialize toolbar control state + Toolbar.INSTANCE.updateDeviceCombo(null); + Toolbar.INSTANCE.updateAppCombo(true); + } + }); + } + }); + deviceinitthread.start(); + + // initialize binary setting + BinarySettingManager.getInstance().initBinarySettings(); + + // initialize some thread + IDECommunicator.startIDECommunicatorThread(); + SideWorker.INSTANCE.start(); + + // delete temp folder + File saveFolder = new File(PathManager.DA_TEMP_FOLDER_PATH); + if (saveFolder.exists()) { + if (AnalyzerUtil.deleteFile(saveFolder)) { + Logger.debug("delete temp folder"); + } else { + Logger.debug("BUG: temp folder is already exists but failed to delete"); + } + } + // if temp save folder does not exist or not a directory + if (!saveFolder.isDirectory()) { + if (!saveFolder.mkdirs()) { + Logger.debug("save folder create failed..."); + } + } + + // Running Setting Dialog + Display.getDefault().asyncExec(new Runnable() { + @Override + public void run() { + final Shell shell = WorkbenchUtil.getWorkbenchWindow().getShell(); + SettingDialog dialog = new SettingDialog(shell); + dialog.open(); + } + }); + + } + @Override public void setFocus() { } @@ -100,7 +182,6 @@ public class BaseView extends ViewPart { // add default pages and interactive page selectedPageSet.add(SettingConstants.PAGE_NAME_TIME_LINE); selectedPageSet.add(SettingConstants.PAGE_NAME_SUMMARY); - // selectedPageSet.add(SettingConstants.PAGE_NAME_MEMORY); if (!InteractiveDataManager.getInstance().getVariableInfoList().isEmpty()) { selectedPageSet.add(SettingConstants.PAGE_NAME_INTERACTIVE); } @@ -152,9 +233,9 @@ public class BaseView extends ViewPart { newPage = new InteractivePage(tabView.getContentComposite(), SWT.NONE); } else if (SettingConstants.PAGE_NAME_HIERARCHY.equals(pageName)) { newPage = new HierarchyPage(tabView.getContentComposite(), SWT.NONE); - } else if (SettingConstants.PAGE_NAME_MEMORY.equals(pageName)) { - newPage = new MemoryPage(tabView.getContentComposite(), SWT.NONE); - } + } //else if (SettingConstants.PAGE_NAME_MEMORY.equals(pageName)) { + // newPage = new MemoryPage(tabView.getContentComposite(), SWT.NONE); + //} // add tab view if (null != newPage) { @@ -195,5 +276,4 @@ public class BaseView extends ViewPart { public void clear() { tabView.clear(); } - -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/ScreenshotTabComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/page/ScreenshotTabComposite.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/range/RangePage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/range/RangePage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/SummaryPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/SummaryPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiDataMaker.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiDataMaker.java index f70879a..865864a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiDataMaker.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiDataMaker.java @@ -41,8 +41,9 @@ import org.tizen.dynamicanalyzer.util.Logger; public class FailedApiDataMaker { private static final String query_withPid = "where %s = %s"; - private static final String query_withTime = "where %s >= %s and %s <= %s order by %s"; - private static final String query_withPidAndTime = "where %s = %s and %s >= %s and %s <= %s order by %s"; + private static final String query_withTime = "where %s >= %s and %s <= %s"; + private static final String query_withPidAndTime = "where %s = %s and %s >= %s and %s <= %s"; + private static final String query_orderby = " order by %s"; private DBInserter failedAPI_DBInserter = null; @@ -117,53 +118,30 @@ public class FailedApiDataMaker { // do nothing } - public List> getFailedApiDataFromDB(int selectedPid) { + public List> getFailedApiDataFromDB(int selectedPid, + List whereQueryList) { String where = null; if (selectedPid != 0) { where = String.format(query_withPid, FailedApiDataDBTable.COLUMN.PID.name, String.valueOf(selectedPid)); } - DBTable table = SummaryDataManager.getInstance().getFailedApiDataDBTable(); - List columns = new ArrayList(); - columns.add(FailedApiDataDBTable.COLUMN.SEQUENCE_NUMBER.name); - columns.add(FailedApiDataDBTable.COLUMN.API_ID.name); - columns.add(FailedApiDataDBTable.COLUMN.PID.name); - columns.add(FailedApiDataDBTable.COLUMN.START_TIME.name); - columns.add(FailedApiDataDBTable.COLUMN.ARGUMENT.name); - columns.add(FailedApiDataDBTable.COLUMN.RETURN_VALUE.name); - columns.add(FailedApiDataDBTable.COLUMN.ERROR_NUMBER.name); - columns.add(FailedApiDataDBTable.COLUMN.CALLER_PC_ADDRESS.name); - columns.add(FailedApiDataDBTable.COLUMN.CALLER_LIBRARY_NAME.name); - columns.add(FailedApiDataDBTable.COLUMN.MESSAGE_ID.name); - - return table.selectData(columns, where, new IResultSet() { - @Override - public List extractDataFromResultSet(ResultSet rs) { - List row = new ArrayList(); - try { - row.add(Long.valueOf(rs.getLong(1))); - row.add(Integer.valueOf(rs.getInt(2))); - row.add(Integer.valueOf(rs.getInt(3))); - row.add(Long.valueOf(rs.getLong(4))); - row.add(rs.getString(5)); - row.add(rs.getString(6)); - row.add(Long.valueOf(rs.getLong(7))); - row.add(Long.valueOf(rs.getLong(8))); - row.add(rs.getString(9)); - row.add(Integer.valueOf(rs.getInt(10))); - } catch (SQLException e) { - Logger.exception(e); - return null; + + if (whereQueryList != null && !whereQueryList.isEmpty()) { + for (int i = 0; i < whereQueryList.size(); i++) { + if (where == null) { + where = " where " + whereQueryList.get(i); //$NON-NLS-1$ + } else { + where += " and " + whereQueryList.get(i); //$NON-NLS-1$ } - - return row; } - }); + } + + return executeQuery(where); } public List> getFailedApiDataFromDBForRange(Long startTime, Long endTime, - int selectedPid) { + int selectedPid, List whereQueryList) { String where = null; if (selectedPid != 0) { where = String.format(query_withPidAndTime, @@ -172,16 +150,26 @@ public class FailedApiDataMaker { FailedApiDataDBTable.COLUMN.START_TIME.name, startTime.toString(), FailedApiDataDBTable.COLUMN.START_TIME.name, - endTime.toString(), - FailedApiDataDBTable.COLUMN.START_TIME.name); + endTime.toString()); } else { where = String.format(query_withTime, FailedApiDataDBTable.COLUMN.START_TIME.name, startTime.toString(), FailedApiDataDBTable.COLUMN.START_TIME.name, - endTime.toString(), - FailedApiDataDBTable.COLUMN.START_TIME.name); + endTime.toString()); + } + + if (whereQueryList != null && !whereQueryList.isEmpty()) { + for (int i = 0; i < whereQueryList.size(); i++) { + where += " and " + whereQueryList.get(i); + } } + where += String.format(query_orderby, FailedApiDataDBTable.COLUMN.START_TIME.name); + + return executeQuery(where); + } + + private List> executeQuery(String whereOption) { DBTable table = SummaryDataManager.getInstance() .getFailedApiDataDBTable(); List columns = new ArrayList(); @@ -196,7 +184,7 @@ public class FailedApiDataMaker { columns.add(FailedApiDataDBTable.COLUMN.CALLER_LIBRARY_NAME.name); columns.add(FailedApiDataDBTable.COLUMN.MESSAGE_ID.name); - return table.selectData(columns, where, new IResultSet() { + return table.selectData(columns, whereOption, new IResultSet() { @Override public List extractDataFromResultSet(ResultSet rs) { List row = new ArrayList(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiListView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiListView.java index 1e719b0..89dd029 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiListView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiListView.java @@ -34,13 +34,13 @@ import org.eclipse.swt.widgets.Control; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.nl.SummaryLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class FailedApiListView extends DAViewComposite { +public class FailedApiListView extends DAAdvancedViewComposite { protected DATableComposite tableComp = null; protected String[] columnNames = { @@ -65,7 +65,7 @@ public class FailedApiListView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_STRING }; public FailedApiListView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(SummaryLabels.FAILED_API_LIST_VIEW_TITLE); @@ -84,6 +84,7 @@ public class FailedApiListView extends DAViewComposite { tableComp.setColumnVisibility(columnVisibility); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiTable.java index 87183e8..d9a7e75 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedApiTable.java @@ -28,6 +28,7 @@ package org.tizen.dynamicanalyzer.ui.summary.failed; import java.util.ArrayList; +import java.util.Iterator; import java.util.List; import org.eclipse.nebula.widgets.grid.GridItem; @@ -38,9 +39,12 @@ import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.error.ErrorCodeManager; import org.tizen.dynamicanalyzer.listeners.SummaryMouseDoubleClickListener; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; +import org.tizen.dynamicanalyzer.nl.SummaryLabels; import org.tizen.dynamicanalyzer.swap.model.data.ProbeCommonData; import org.tizen.dynamicanalyzer.ui.range.RangeDataManager; import org.tizen.dynamicanalyzer.ui.range.RangePage; @@ -190,42 +194,123 @@ public class FailedApiTable extends DATableComposite { protected List makeTableInput() { List> failedData = null; int selectedPid = Toolbar.INSTANCE.getSelectedPid(); - if (isRange) { - Long markerStartTime = Long.valueOf(RangeDataManager.getInstance() - .getMarkerStartTime()); - Long markerEndTime = Long.valueOf(RangeDataManager.getInstance() - .getMarkerEndTime()); - failedData = failedApiDataMaker.getFailedApiDataFromDBForRange( - markerStartTime, markerEndTime, selectedPid); + List filterList = getFilterList(); + if (!filterList.isEmpty()) { + // if filter is set by user + List whereQueryList = convertFilterProperty2Query(filterList); + if (isRange) { + Long markerStartTime = Long.valueOf(RangeDataManager.getInstance() + .getMarkerStartTime()); + Long markerEndTime = Long.valueOf(RangeDataManager.getInstance() + .getMarkerEndTime()); + failedData = failedApiDataMaker.getFailedApiDataFromDBForRange( + markerStartTime, markerEndTime, selectedPid, whereQueryList); + } else { + failedData = failedApiDataMaker.getFailedApiDataFromDB(selectedPid, + whereQueryList); + } } else { - failedData = failedApiDataMaker.getFailedApiDataFromDB(selectedPid); + if (isRange) { + Long markerStartTime = Long.valueOf(RangeDataManager.getInstance() + .getMarkerStartTime()); + Long markerEndTime = Long.valueOf(RangeDataManager.getInstance() + .getMarkerEndTime()); + failedData = failedApiDataMaker.getFailedApiDataFromDBForRange( + markerStartTime, markerEndTime, selectedPid, null); + } else { + failedData = failedApiDataMaker.getFailedApiDataFromDB(selectedPid, null); + } } if (failedData == null) return null; List input = new ArrayList(); int size = failedData.size(); + + tableDataLoops: for (int i = 0; i < size; i++) { List idata = failedData.get(i); - // create text + long time = (Long) idata + .get(FailedApiDataDBTable.COLUMN.START_TIME.index); + String timeFormat = null; + try { + timeFormat = Formatter.toTimeFormat(time); + } catch (NumberFormatException e) { + Logger.exception(e); + timeFormat = Long.toString(time); + } + + int apiId = (Integer) idata + .get(FailedApiDataDBTable.COLUMN.API_ID.index); + String apiName = Global.getFunctionName(apiId); + + long errNum = (Long) idata + .get(FailedApiDataDBTable.COLUMN.ERROR_NUMBER.index); + String errCode = null; + try { + errCode = ErrorCodeManager.getInatance() + .getErrorCode(errNum).name(); + if (null == errCode) { + errCode = SummaryLabels.FAILED_API_LIST_UNDEFINED_ERROR_NUMBER; + } + } catch (NullPointerException e) { + Logger.exception(e); + errCode = SummaryLabels.FAILED_API_LIST_UNDEFINED_ERROR_NUMBER; + } + + String errMsg = ErrorCodeManager.getInatance().getErrorDescription( + errNum); + if (null == errMsg) { + errMsg = SummaryLabels.FAILED_API_LIST_UNDEFINED_ERROR_NUMBER; + } + + // check for filter data of the excluded columns + // from the process of creating a filter query + for (int index = 0; index < filterList.size(); index++) { + switch (filterList.get(index).getColumnIndex()) { + case 1: // start time + if (!timeFormat.toLowerCase().contains( + filterList.get(index).getKeyWord().toLowerCase())) { + continue tableDataLoops; + } + break; + case 2: // api name + if (!apiName.toLowerCase().contains( + filterList.get(index).getKeyWord().toLowerCase())) { + continue tableDataLoops; + } + break; + case 5: // error code + if (!errCode.toLowerCase().contains( + filterList.get(index).getKeyWord().toLowerCase())) { + continue tableDataLoops; + } + break; + case 6: // error message + if (!errMsg.toLowerCase().contains( + filterList.get(index).getKeyWord().toLowerCase())) { + continue tableDataLoops; + } + break; + default: + break; + } + } + + // create table text & data List text = new ArrayList(); List data = new ArrayList(); - + // 0 : sequence number Long seq = (Long) idata .get(FailedApiDataDBTable.COLUMN.SEQUENCE_NUMBER.index); text.add(Long.toString(seq)); data.add(Long.valueOf(seq)); // 1 : start time - long time = (Long) idata - .get(FailedApiDataDBTable.COLUMN.START_TIME.index); - text.add(Formatter.toTimeFormat(time)); + text.add(timeFormat); data.add(Long.valueOf(time)); // 2 : api name - int apiId = (Integer) idata - .get(FailedApiDataDBTable.COLUMN.API_ID.index); - String apiName = Global.getFunctionName(apiId); text.add(apiName); data.add(apiName); // 3 : arguments @@ -238,29 +323,9 @@ public class FailedApiTable extends DATableComposite { .get(FailedApiDataDBTable.COLUMN.RETURN_VALUE.index); text.add(retValue); data.add(retValue); - - long errNum = (Long) idata - .get(FailedApiDataDBTable.COLUMN.ERROR_NUMBER.index); - try { - String errCode = ErrorCodeManager.getInatance() - .getErrorCode(errNum).name(); - if (null == errCode) { - // FIXME : for debug - errCode = "undefined error number"; //$NON-NLS-1$ - } - // 5 : error code - text.add(errCode); - data.add(Long.valueOf(errNum)); - } catch (NullPointerException e) { - Logger.debug("debug"); - continue; - } - String errMsg = ErrorCodeManager.getInatance().getErrorDescription( - errNum); - if (null == errMsg) { - // FIXME : for debug - errMsg = "undefined error number"; //$NON-NLS-1$ - } + // 5 : error code + text.add(errCode); + data.add(Long.valueOf(errNum)); // 6 : error message text.add(errMsg); data.add(Long.valueOf(errNum)); @@ -318,4 +383,55 @@ public class FailedApiTable extends DATableComposite { } return input; } + + private List getFilterList() { + List filterList = getFilterPropertyList(); + if (!filterList.isEmpty()) { + List filterListRep = new ArrayList(); + filterListRep.addAll(filterList); + return filterListRep; + } else { + return filterList; + } + } + + @Override + protected List convertFilterProperty2Query(List filterList) { + List queries = new ArrayList(); + + Iterator iter = filterList.iterator(); + while (iter.hasNext()) { + FilterProperty prop = iter.next(); + String queryPrefix = getFilteredColumnName(prop.getColumnIndex()); + if (queryPrefix != null) { + queries.add(makeFilterWhereClause(queryPrefix, prop.getKeyWord())); + iter.remove(); + } + } + + return queries; + } + + /** excluded columns : Start time, + API(api name), + Error code, + Error message, **/ + @Override + protected String getFilteredColumnName(int index) { + String columnName = null; + switch (index) { + case 3: + columnName = addLowerOperation(FailedApiDataDBTable.COLUMN.ARGUMENT.name); + break; + case 4: + columnName = addLowerOperation(FailedApiDataDBTable.COLUMN.RETURN_VALUE.name); + break; + case 7: + columnName = FailedApiDataDBTable.COLUMN.PID.name; + break; + default: + break; + } + return columnName; + } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedData.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/failed/FailedData.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakDataMaker.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakDataMaker.java index 787127d..aa0f98a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakDataMaker.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakDataMaker.java @@ -35,6 +35,7 @@ import java.util.Map; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DALimit; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.database.DBInserter; import org.tizen.dynamicanalyzer.database.DBTable; import org.tizen.dynamicanalyzer.database.IResultSet; @@ -192,10 +193,8 @@ public class LeakDataMaker { memoryAllocDataList.clear(); freeDataList.clear(); } - - public List> getAllocationDataFromDB(Long seq) { - String where = String.format(query_withSeq, - MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.name, seq); + + private List> executeQuery(String where) { DBTable table = SummaryDataManager.getInstance().getMemoryAllocationDataDBTable(); List columns = new ArrayList(); columns.add(MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.name); @@ -236,6 +235,13 @@ public class LeakDataMaker { }); } + public List> getAllocationDataFromDB(Long seq) { + String where = String.format(query_withSeq, + MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.name, seq); + + return executeQuery(where); + } + public List> getLeakDataFromDB() { DBTable table = SummaryDataManager.getInstance().getLeakDataDBTable(); List columns = new ArrayList(); @@ -261,53 +267,26 @@ public class LeakDataMaker { }); } - public List> getLeakDataWithSeq(List leakSequenceNumbers) { + public List> getLeakDataWithSeq(List leakSequenceNumbers, + List whereQueryList) { String where = String.format(query_withSeqList, MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.name); int size = leakSequenceNumbers.size(); for (int i = 0; i < size - 1; i++) { - where += String.valueOf(leakSequenceNumbers.get(i)) + ", "; + where += String.valueOf(leakSequenceNumbers.get(i)) + CommonConstants.COMMA + + CommonConstants.SPACE; } - where += String.valueOf(leakSequenceNumbers.get(size - 1)) + ")"; - - DBTable table = SummaryDataManager.getInstance().getMemoryAllocationDataDBTable(); - List columns = new ArrayList(); - columns.add(MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.PID.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.API_ID.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.API_TYPE.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_ADDRESS.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.CALLER_PC_ADDRESS.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.ARGUMENT.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.RETURN_VALUE.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.CALLER_LIBRARY_NAME.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.MESSAGE_ID.name); - - return table.selectData(columns, where, new IResultSet() { - @Override - public List extractDataFromResultSet(ResultSet rs) { - List row = new ArrayList(); - try { - row.add(Long.valueOf(rs.getLong(1))); - row.add(Integer.valueOf(rs.getInt(2))); - row.add(Integer.valueOf(rs.getInt(3))); - row.add(Integer.valueOf(rs.getInt(4))); - row.add(Long.valueOf(rs.getLong(5))); - row.add(Long.valueOf(rs.getLong(6))); - row.add(Long.valueOf(rs.getLong(7))); - row.add(rs.getString(8)); - row.add(rs.getString(9)); - row.add(rs.getString(10)); - row.add(Integer.valueOf(rs.getInt(11))); - } catch (SQLException e) { - Logger.exception(e); - return null; - } - return row; + where += String.valueOf(leakSequenceNumbers.get(size - 1)) + CommonConstants.CLOSE_BRACKET; + + if (whereQueryList != null && !whereQueryList.isEmpty()) { + // if 'WHERE' condition used on the DB query is existed + for (int i = 0; i < whereQueryList.size(); i++) { + where += " and " + whereQueryList.get(i); } - }); + } + + return executeQuery(where); } public List> getLeakDataForRange() { @@ -395,44 +374,8 @@ public class LeakDataMaker { MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.name, startTime.toString(), MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.name, endTime.toString(), MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.name); - DBTable table = SummaryDataManager.getInstance().getMemoryAllocationDataDBTable(); - List columns = new ArrayList(); - columns.add(MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.PID.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.API_ID.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.API_TYPE.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_ADDRESS.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.CALLER_PC_ADDRESS.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.ARGUMENT.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.RETURN_VALUE.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.CALLER_LIBRARY_NAME.name); - columns.add(MemoryAllocationDataDBTable.COLUMN.MESSAGE_ID.name); - - return table.selectData(columns, where, new IResultSet() { - @Override - public List extractDataFromResultSet(ResultSet rs) { - List row = new ArrayList(); - try { - row.add(Long.valueOf(rs.getLong(1))); - row.add(Integer.valueOf(rs.getInt(2))); - row.add(Integer.valueOf(rs.getInt(3))); - row.add(Integer.valueOf(rs.getInt(4))); - row.add(Long.valueOf(rs.getLong(5))); - row.add(Long.valueOf(rs.getLong(6))); - row.add(Long.valueOf(rs.getLong(7))); - row.add(rs.getString(8)); - row.add(rs.getString(9)); - row.add(rs.getString(10)); - row.add(Integer.valueOf(rs.getInt(11))); - } catch (SQLException e) { - Logger.exception(e); - return null; - } - - return row; - } - }); + + return executeQuery(where); } private List> getFreeDataWithPidFromDBForRange(Long startTime, Long endTime, diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakTable.java index b6d4302..2b65bac 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakTable.java @@ -28,6 +28,7 @@ package org.tizen.dynamicanalyzer.ui.summary.leaks; import java.util.ArrayList; +import java.util.Iterator; import java.util.List; import java.util.Map; @@ -42,7 +43,9 @@ import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.listeners.SummaryMouseDoubleClickListener; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.swap.model.data.LogDataFactory; import org.tizen.dynamicanalyzer.swap.model.data.ProbeCommonData; @@ -59,8 +62,6 @@ import org.tizen.dynamicanalyzer.utils.Formatter; public class LeakTable extends DATreeComposite { private boolean isRange = false; - private final LeakDataMaker leakDataMaker = SummaryDataManager.getInstance().getLeakDataMaker(); - public LeakTable(Composite parent, int compStyle, int tableStyle) { super(parent, compStyle, tableStyle); setContextMenu(AnalyzerConstants.CONTEXT_TABLE_RANGE); @@ -158,6 +159,7 @@ public class LeakTable extends DATreeComposite { List output = new ArrayList(); Map leaks = null; List> leakDataList = null; + List filterList = getFilterList(); // TODO : make hashkey (LogData.getKey() --> combination of pid and // address) if (isRange) { @@ -165,16 +167,23 @@ public class LeakTable extends DATreeComposite { .getLeakDataForRange(); } else { leaks = AnalyzerManager.getNewLeakDetector().getLeakHash(); - if (leaks == null || leaks.size() < 1) + if (leaks == null || leaks.isEmpty()) return output; - ArrayList leakList = new ArrayList(); - leakList.addAll(leaks.values()); + List leakSeqNumList = new ArrayList(); - for (int i = 0; i < leakList.size(); i++) - leakSeqNumList.add(leakList.get(i).getSequenceNumber()); + for (Integer key : leaks.keySet()) { + leakSeqNumList.add(leaks.get(key).getSequenceNumber()); + } - leakDataList = SummaryDataManager.getInstance().getLeakDataMaker() - .getLeakDataWithSeq(leakSeqNumList); + if (!filterList.isEmpty()) { + // if filter is set by user + List whereQueryList = convertFilterProperty2Query(filterList); + leakDataList = SummaryDataManager.getInstance().getLeakDataMaker() + .getLeakDataWithSeq(leakSeqNumList, whereQueryList); + } else { + leakDataList = SummaryDataManager.getInstance().getLeakDataMaker() + .getLeakDataWithSeq(leakSeqNumList, null); + } } if (leakDataList == null) @@ -182,6 +191,7 @@ public class LeakTable extends DATreeComposite { // TODO : it is necessary to consider when choosing a multi-processes. int selectedPid = Toolbar.INSTANCE.getSelectedPid(); int size = leakDataList.size(); + for (int i = 0; i < size; i++) { List iLeakData = leakDataList.get(i); if (!isRange) { @@ -192,8 +202,8 @@ public class LeakTable extends DATreeComposite { } } } - - TreeInput leakInput = makeTreeInputForLeakData(iLeakData, i); + + TreeInput leakInput = makeTreeInputForLeakData(iLeakData, i, filterList); if (leakInput != null){ output.add(leakInput); } @@ -202,179 +212,147 @@ public class LeakTable extends DATreeComposite { return output; } - private TreeInput makeTreeInputForLeakData(List leakData, int index) { - // TODO : need understand for the DATableDataFormat class - DATableDataFormat tableData = new DATableDataFormat(index); - - List text = new ArrayList(); - List data = new ArrayList(); + private TreeInput makeTreeInputForLeakData(List leakData, int index, + List filterList) { TreeInput output = null; if (leakData == null) { Logger.error("very strange case !!"); return null; } - // 0 : sequence number - hidden column for sorting + Long seq = (Long) leakData.get(MemoryAllocationDataDBTable.COLUMN.SEQUENCE_NUMBER.index); - text.add(Long.toString(seq)); - data.add(seq); - // 1 : column empty value for tree + int apiId = (Integer) leakData.get(MemoryAllocationDataDBTable.COLUMN.API_ID.index); String apiName = Global.getFunctionName(apiId); - text.add(apiName); - data.add(apiName); - // 2 : pid + int pid = (Integer) leakData.get(MemoryAllocationDataDBTable.COLUMN.PID.index); - text.add(Integer.toString(pid)); - data.add(pid); - // 3 : message id + String pidString = Integer.toString(pid); + int id = (Integer) leakData.get(MemoryAllocationDataDBTable.COLUMN.MESSAGE_ID.index); String type = LogDataFactory.getLogFormatName(id); - text.add(type); - data.add(type); - // 4 : allocated time + long time = (Long) leakData.get(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.index); - data.add(Long.valueOf(time)); + String timeFormat = null; try { - text.add(Formatter.toTimeFormat(time)); - } catch (NumberFormatException e) { + timeFormat = Formatter.toTimeFormat(time); + } catch(NumberFormatException e) { Logger.exception(e); - text.add(Long.toString(time)); + timeFormat = Long.toString(time); } - tableData.setObject(apiName); - // 5 : arguments String args = (String) leakData.get(MemoryAllocationDataDBTable.COLUMN.ARGUMENT.index); - text.add(args); - data.add(args); - // 6 : return value + String retValue = (String) leakData - .get(MemoryAllocationDataDBTable.COLUMN.RETURN_VALUE.index); - text.add(retValue); - data.add(retValue); - // 7 : library name + .get(MemoryAllocationDataDBTable.COLUMN.RETURN_VALUE.index); + String libName = (String) leakData .get(MemoryAllocationDataDBTable.COLUMN.CALLER_LIBRARY_NAME.index); if (libName == null || libName.isEmpty()) { - // TODO : replace another one ?? libName = AnalyzerConstants.UNKNOWN_LIB; } - text.add(libName); - data.add(libName); - // 8 : for ToolTip Listener - data.add((Long) leakData.get(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_ADDRESS.index)); - // 9 : caller pc address - long callerPcAddr = (Long) leakData - .get(MemoryAllocationDataDBTable.COLUMN.CALLER_PC_ADDRESS.index); - data.add(callerPcAddr); - - tableData.getData().addAll(data); - tableData.setType(AnalyzerConstants.TYPE_TABLE_LEAK); - - ProbeCommonData probeData = new ProbeCommonData(); - probeData.setSeq(seq); - probeData.setApiName(apiName); - probeData.setMsgID(id); - probeData.setPid(pid); - probeData.setTime(time); - probeData.setArgs(args); - probeData.setReturn(retValue); - probeData.setCallerAddress(callerPcAddr); - probeData.setLibName(libName); - tableData.setLogData(probeData); - - output = new TreeInput(); - output.setText(text); - output.setData(tableData); - // output.setParent(Integer.toString(leakData.getParentKey())); - - if (RangeDataManager.getInstance().isBeingAnalyzed()) { - long leakTime = time; - long startTime = RangeDataManager.getInstance().getAnalysisStartTime(); - long endTime = RangeDataManager.getInstance().getAnalysisEndTime(); - if (leakTime >= startTime && leakTime <= endTime) { - output.setInRange(true); + + // check for filter data of the excluded columns + // from the process of creating a filter query + // (check for all filter data for the range analysis) + for (int i = 0; i < filterList.size(); i++) { + switch(filterList.get(i).getColumnIndex()) { + case 1: // API(api name) + if (apiName.toLowerCase().contains(filterList.get(i).getKeyWord().toLowerCase())) { + break; + } else { + return output; + } + case 2: // pid + if (isRange) { + if (pidString.contains(filterList.get(i).getKeyWord())) { + break; + } else { + return output; + } + } + break; + case 3: // Category(log format name) + if (type.toLowerCase().contains(filterList.get(i).getKeyWord().toLowerCase())) { + break; + } else { + return output; + } + case 4: // Time(allocated time) + if (timeFormat.toLowerCase().contains(filterList.get(i).getKeyWord().toLowerCase())) { + break; + } else { + return output; + } + case 5: // arguments + if (isRange) { + if (args.toLowerCase().contains(filterList.get(i).getKeyWord().toLowerCase())) { + break; + } else { + return output; + } + } + break; + case 6: // return value + if (isRange) { + if (retValue.toLowerCase().contains( + filterList.get(i).getKeyWord().toLowerCase())) { + break; + } else { + return output; + } + } + break; + case 7: // library name + if (isRange) { + if (libName.toLowerCase() + .contains(filterList.get(i).getKeyWord().toLowerCase())) { + break; + } else { + return output; + } + } + break; + default: + break; } } - - return output; - } - - @SuppressWarnings("unused") - private TreeInput makeTreeInputForLeaks(CurrentLeakData leakInfo, int index) { - // TODO : need understand for the DATableDataFormat class - DATableDataFormat tableData = new DATableDataFormat(index); - + + // create table text & data List text = new ArrayList(); List data = new ArrayList(); - TreeInput output = null; - - Long seq = leakInfo.getSequenceNumber(); - List> leakData = leakDataMaker.getAllocationDataFromDB(seq); - if (leakData == null) { - Logger.error("very strange case !!"); - return null; - } - if (leakData.size() != 1) { // size of leakData must be 1 - Logger.error("size of leakDataMaker.getLeakDataFromDB() is not '1'"); - return output; - } - List idata = leakData.get(0); - // 0 : column empty value for tree - int apiId = (Integer) idata.get(MemoryAllocationDataDBTable.COLUMN.API_ID.index); - String apiName = Global.getFunctionName(apiId); + + // 0 : sequence number - hidden column for sorting + text.add(Long.toString(seq)); + data.add(seq); + // 1 : api name text.add(apiName); data.add(apiName); - // 1 : pid - int pid = (Integer) idata.get(MemoryAllocationDataDBTable.COLUMN.PID.index); - text.add(Integer.toString(pid)); + // 2 : pid + text.add(pidString); data.add(pid); - // 2 : sequence number - text.add(Long.toString(seq)); - data.add(seq); // 3 : message id - int id = (Integer) idata.get(MemoryAllocationDataDBTable.COLUMN.MESSAGE_ID.index); - String type = LogDataFactory.getLogFormatName(id); text.add(type); data.add(type); - // 4 : allocated time - long time = (Long) idata.get(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_TIME.index); + // 4 : allocated time + text.add(timeFormat); data.add(Long.valueOf(time)); - try { - text.add(Formatter.toTimeFormat(time)); - } catch (NumberFormatException e) { - Logger.exception(e); - text.add(Long.toString(time)); - } - - tableData.setObject(apiName); // 5 : arguments - String args = (String) idata.get(MemoryAllocationDataDBTable.COLUMN.ARGUMENT.index); text.add(args); data.add(args); // 6 : return value - String retValue = (String) idata.get(MemoryAllocationDataDBTable.COLUMN.RETURN_VALUE.index); text.add(retValue); data.add(retValue); // 7 : library name - String libName = (String) idata - .get(MemoryAllocationDataDBTable.COLUMN.CALLER_LIBRARY_NAME.index); - if (libName == null || libName.isEmpty()) { - // TODO : replace another one ?? - libName = AnalyzerConstants.UNKNOWN_LIB; - } text.add(libName); data.add(libName); // 8 : for ToolTip Listener - data.add((Long) idata.get(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_ADDRESS.index)); + data.add((Long) leakData.get(MemoryAllocationDataDBTable.COLUMN.ALLOCATED_ADDRESS.index)); // 9 : caller pc address - long callerPcAddr = (Long) idata + long callerPcAddr = (Long) leakData .get(MemoryAllocationDataDBTable.COLUMN.CALLER_PC_ADDRESS.index); data.add(callerPcAddr); - tableData.getData().addAll(data); - tableData.setType(AnalyzerConstants.TYPE_TABLE_LEAK); - ProbeCommonData probeData = new ProbeCommonData(); probeData.setSeq(seq); probeData.setApiName(apiName); @@ -385,6 +363,11 @@ public class LeakTable extends DATreeComposite { probeData.setReturn(retValue); probeData.setCallerAddress(callerPcAddr); probeData.setLibName(libName); + + DATableDataFormat tableData = new DATableDataFormat(index); + tableData.setType(AnalyzerConstants.TYPE_TABLE_LEAK); + tableData.getData().addAll(data); + tableData.setObject(apiName); tableData.setLogData(probeData); output = new TreeInput(); @@ -403,4 +386,56 @@ public class LeakTable extends DATreeComposite { return output; } + + private List getFilterList() { + List filterList = getFilterPropertyList(); + if (!filterList.isEmpty()) { + List filterListRep = new ArrayList(); + filterListRep.addAll(filterList); + return filterListRep; + } else { + return filterList; + } + } + + @Override + protected List convertFilterProperty2Query(List filterList) { + List queries = new ArrayList(); + + Iterator iter = filterList.iterator(); + while (iter.hasNext()) { + FilterProperty prop = iter.next(); + String queryPrefix = getFilteredColumnName(prop.getColumnIndex()); + if (queryPrefix != null) { + queries.add(makeFilterWhereClause(queryPrefix, prop.getKeyWord())); + iter.remove(); + } + } + + return queries; + } + + // excluded columns : API(api name), Category(log format name), Time(allocated time) + @Override + protected String getFilteredColumnName(int index) { + String columnName = null; + switch (index) { + case 2: + columnName = MemoryAllocationDataDBTable.COLUMN.PID.name; + break; + case 5: + columnName = addLowerOperation(MemoryAllocationDataDBTable.COLUMN.ARGUMENT.name); + break; + case 6: + columnName = addLowerOperation(MemoryAllocationDataDBTable.COLUMN.RETURN_VALUE.name); + break; + case 7: + columnName = addLowerOperation(MemoryAllocationDataDBTable.COLUMN.CALLER_LIBRARY_NAME.name); + break; + default: + break; + } + + return columnName; + } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakView.java index 7b172b6..09bf44a 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/leaks/LeakView.java @@ -35,13 +35,14 @@ import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; import org.tizen.dynamicanalyzer.nl.SummaryLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DATreeComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.ui.widgets.table.TreeDataComparator; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class LeakView extends DAViewComposite { +public class LeakView extends DAAdvancedViewComposite { protected String[] columnNames = {SummaryLabels.LEAK_VIEW_INDEX, SummaryLabels.LEAK_VIEW_NAME, SummaryLabels.LEAK_VIEW_PID, SummaryLabels.LEAK_VIEW_TYPE, SummaryLabels.LEAK_VIEW_TIME, @@ -60,7 +61,7 @@ public class LeakView extends DAViewComposite { protected DATreeComposite treeComp = null; public LeakView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(SummaryLabels.LEAK_VIEW_TITLE_LEAK); @@ -83,6 +84,7 @@ public class LeakView extends DAViewComposite { contents.addControlListener(new TableColumnSizePackListener(treeComp, columnSizes)); + setTable(treeComp); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingTableCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingTableCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingView.java index bc7305c..26d4e46 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/FunctionUsageProfilingView.java @@ -112,4 +112,4 @@ public class FunctionUsageProfilingView extends DAViewComposite { webTable.setRangeTable(isRange); } } -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/ProfilingTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/ProfilingTable.java index 0035d31..b007dca 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/ProfilingTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/profiling/ProfilingTable.java @@ -37,29 +37,36 @@ import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.SWT; import org.eclipse.swt.events.MouseEvent; import org.eclipse.swt.events.MouseListener; +import org.eclipse.swt.events.PaintEvent; +import org.eclipse.swt.events.PaintListener; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; +import org.eclipse.swt.graphics.GC; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Event; import org.eclipse.swt.widgets.Listener; +import org.eclipse.swt.widgets.Shell; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.model.ColumnData; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.nl.SummaryLabels; import org.tizen.dynamicanalyzer.ui.range.RangeDataManager; import org.tizen.dynamicanalyzer.ui.range.RangePage; import org.tizen.dynamicanalyzer.ui.summary.SummaryPage; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; +import org.tizen.dynamicanalyzer.ui.widgets.FilterDialog; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableDataFormat; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableHeaderRenderer; import org.tizen.dynamicanalyzer.ui.widgets.table.DATreeComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; import org.tizen.dynamicanalyzer.ui.widgets.table.TreeDataComparator; import org.tizen.dynamicanalyzer.util.Logger; +import org.tizen.dynamicanalyzer.util.WorkbenchUtil; import org.tizen.dynamicanalyzer.utils.Formatter; public class ProfilingTable extends DATreeComposite { @@ -220,6 +227,75 @@ public class ProfilingTable extends DATreeComposite { } } } + + @Override + public List getColumnsName() { + List columnsName = new ArrayList(); + GridColumnGroup[] columnGroups = table.getColumnGroups(); + GridColumn[] columns = table.getColumns(); + + /* lib/func name */ + columnsName.add(columns[0].getText()); + + /* exclusive group */ + columnsName.add(SummaryLabels.FUNCTION_USER_PROFILING_VIEW_EXCLUSIVE_PREFIX + + (columnGroups[0].getColumns())[0].getText()); + columnsName.add(SummaryLabels.FUNCTION_USER_PROFILING_VIEW_EXCLUSIVE_PREFIX + + (columnGroups[0].getColumns())[1].getText()); + columnsName.add(SummaryLabels.FUNCTION_USER_PROFILING_VIEW_EXCLUSIVE_PREFIX + + (columnGroups[0].getColumns())[2].getText()); + + /* inclusive group */ + columnsName.add(SummaryLabels.FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_PREFIX + + (columnGroups[1].getColumns())[0].getText()); + columnsName.add(SummaryLabels.FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_PREFIX + + (columnGroups[1].getColumns())[1].getText()); + columnsName.add(SummaryLabels.FUNCTION_USER_PROFILING_VIEW_INCLUSIVE_PREFIX + + (columnGroups[1].getColumns())[2].getText()); + + /* call count */ + columnsName.add(columns[1].getText()); + + return columnsName; + } + + @Override + protected void applyFilterImage() { + table.addPaintListener(new PaintListener() { + + @Override + public void paintControl(PaintEvent e) { + GC gc = e.gc; + GridColumnGroup[] columnGroups = table.getColumnGroups(); + GridColumn[] columns = table.getColumns(); + List filterProperties = getFilterPropertyList(); + for (int i = 0; i < filterProperties.size(); i++) { + int columnIndex = filterProperties.get(i).getColumnIndex(); + int y = 0; + if (columns[columnIndex].isVisible()) { + switch(columnIndex) { + case 0: + case 7: + y = columnGroups[0].getHeaderRenderer().getBounds().height / 2; + break; + case 1: // included in the column group + case 2: + case 3: + case 4: + case 5: + case 6: + y = columnGroups[0].getHeaderRenderer().getBounds().height; + break; + default: + Logger.error("wrong column index - " + columnIndex); + break; + } + gc.drawImage(filterImg, getFilterImagePosition(columnIndex), y); + } + } + } + }); + } private List getPidsOfProfileDataMakerMap() { if (isRange) { @@ -273,10 +349,14 @@ public class ProfilingTable extends DATreeComposite { final int columnIndex = index; column.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent event) { - comparator.setType(type); - comparator.setColumn(columnIndex); - comparator.reverseDirection(); - updateTree(); + if (checkAndOpenFilterDialog(columnIndex)) { + return; + } else { + comparator.setType(type); + comparator.setColumn(columnIndex); + comparator.reverseDirection(); + updateTree(); + } } }); } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningListView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningListView.java index c13718c..63e65e5 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningListView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningListView.java @@ -35,6 +35,7 @@ import org.eclipse.swt.widgets.Control; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.nl.SummaryLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.DefaultTableComparator; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; @@ -42,7 +43,7 @@ import org.tizen.dynamicanalyzer.widgets.da.view.DAPageComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class WarningListView extends DAViewComposite { +public class WarningListView extends DAAdvancedViewComposite { protected DATableComposite tableComp = null; protected String[] columnNames = { SummaryLabels.WARNING_LIST_VIEW_INDEX, SummaryLabels.WARNING_LIST_VIEW_CATEGORY, @@ -55,7 +56,7 @@ public class WarningListView extends DAViewComposite { AnalyzerConstants.SORT_TYPE_GRID }; public WarningListView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(SummaryLabels.WARNING_LIST_VIEW_TITLE); @@ -73,6 +74,7 @@ public class WarningListView extends DAViewComposite { tableComp.setTableName(SummaryLabels.WARNING_LIST_VIEW_TITLE); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } @Override diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningTable.java index 6d7319a..367082d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/summary/warning/WarningTable.java @@ -38,6 +38,7 @@ import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.listeners.SummaryMouseDoubleClickListener; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.swap.model.data.LogDataFactory; import org.tizen.dynamicanalyzer.swap.model.data.ProbeCommonData; @@ -139,8 +140,11 @@ public class WarningTable extends DATableComposite { warningData = warningDataMaker.getWarningDataList(); if (warningData == null) return null; + List filterList = getFilterPropertyList(); List input = new ArrayList(); int size = warningData.size(); + + tableDataLoops: for (int i = 0; i < size; i++) { List idata = warningData.get(i); @@ -155,32 +159,60 @@ public class WarningTable extends DATableComposite { if(!isVaildData(idata)){ continue; } + + int msgID = (Integer) idata + .get(WarningDataDBTable.COLUMN.MESSAGE_ID.index); + String category = LogDataFactory.getLogFormatName(msgID); - // create text + String pidString = Integer.toString(pid); + + int warningCase = (Integer) idata + .get(WarningDataDBTable.COLUMN.WARNING_CASE.index); + String message = WarningCase.getShortWarningMessage(warningCase); + + // check for filter data + for (int index = 0; index < filterList.size(); index++) { + switch (filterList.get(index).getColumnIndex()) { + case 1: // category + if (!category.toLowerCase().contains( + filterList.get(index).getKeyWord().toLowerCase())) { + continue tableDataLoops; + } + break; + case 2: // pid + if (!pidString.contains(filterList.get(index).getKeyWord())) { + continue tableDataLoops; + } + break; + case 3: // warning message + if (!message.toLowerCase().contains( + filterList.get(index).getKeyWord().toLowerCase())) { + continue tableDataLoops; + } + break; + default: + break; + } + } + + // create table text & data List text = new ArrayList(); List data = new ArrayList(); - + // 0 : rid int rid = (Integer) idata.get(WarningDataDBTable.COLUMN.RID.index); text.add(Integer.toString(rid)); data.add(Integer.toString(rid)); // 1 : message id - int msgID = (Integer) idata - .get(WarningDataDBTable.COLUMN.MESSAGE_ID.index); - String category = LogDataFactory.getLogFormatName(msgID); text.add(category); data.add(category); // 2 : pid - text.add(Integer.toString(pid)); - data.add(Integer.toString(pid)); + text.add(pidString); + data.add(pidString); // 3 : short warning message - int warningCase = (Integer) idata - .get(WarningDataDBTable.COLUMN.WARNING_CASE.index); - String message = WarningCase.getShortWarningMessage(warningCase); text.add(message); data.add(message); - // create images - + // create DATableDataFormat long seq = (Long)idata.get(WarningDataDBTable.COLUMN.SEQUENCE_NUMBER.index); DATableDataFormat tableData = new DATableDataFormat(seq); @@ -198,7 +230,7 @@ public class WarningTable extends DATableComposite { .get(WarningDataDBTable.COLUMN.CALLER_PC_ADDRESS.index)); probeData.setLibName((String) idata .get(WarningDataDBTable.COLUMN.CALLER_LIBRARY_NAME.index)); - tableData.getData().addAll(text); + tableData.getData().addAll(data); tableData.setLogData(probeData); tableData.setType(AnalyzerConstants.TYPE_TABLE_WARNING); TableInput tableInput = new TableInput(); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListTable.java index 6508109..3065f79 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListTable.java @@ -34,14 +34,18 @@ import java.util.Collections; import java.util.Comparator; import java.util.List; +import org.eclipse.nebula.widgets.grid.GridColumn; import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; +import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.database.DBConstants; import org.tizen.dynamicanalyzer.database.SqlConnectionManager; import org.tizen.dynamicanalyzer.error.ErrorCodeManager; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.swap.model.data.ProbeCommonData; import org.tizen.dynamicanalyzer.swap.model.data.SyncData; @@ -120,28 +124,42 @@ public class ThreadAPIListTable extends DAApiListTableComposite { int selectID = -1; List syncAPIList = new ArrayList(); + // get filter list + List filterList = getFilterPropertyList(); if (data instanceof ThreadPageThreadData) { ThreadPageThreadData tData = (ThreadPageThreadData) data; selectID = tData.getThreadDataID(); } else if (data instanceof ThreadPageSyncData) { ThreadPageSyncData sData = (ThreadPageSyncData) data; selectID = sData.getSyncDataID(); - syncAPIList.addAll(getSyncAPIOfNotInsert(selectID)); + syncAPIList.addAll(getSyncAPIOfNotInsert(selectID, filterList)); } else { Logger.debug("failed to selectionD data in Thread Page API table"); return null; } - syncAPIList.addAll(selectAPIListFromDB(data, selectID)); + syncAPIList.addAll(selectAPIListFromDB(data, selectID, filterList)); sortListByTime(syncAPIList); for (ProbeCommonData apiData : syncAPIList) { + String timeText = Formatter.toTimeFormat(apiData.getTime()); + String apiName = apiData.getApiName(); + String errMsg = ErrorCodeManager.getInatance().getErrorCode(apiData.getErrno()).name(); + if (null == errMsg) { + errMsg = "undefined error code"; //$NON-NLS-1$ + } + + // check filter condition : Time, API name, Error Code + if (!filterAfterDB(filterList, timeText, apiName, errMsg)) { + continue; + } // else : data appear in the table + List contentText = new ArrayList(); List contentData = new ArrayList(); contentText.add(0, String.valueOf(apiData.getSeq())); contentData.add(String.valueOf(apiData.getSeq())); - contentText.add(Formatter.toTimeFormat(apiData.getTime())); + contentText.add(timeText); contentData.add(Long.toString(apiData.getTime())); contentText.add(Integer.toString(apiData.getPid())); @@ -150,8 +168,8 @@ public class ThreadAPIListTable extends DAApiListTableComposite { contentText.add(Long.toString(apiData.getTid())); contentData.add(Long.toString(apiData.getTid())); - contentText.add(apiData.getApiName()); - contentData.add(apiData.getApiName()); + contentText.add(apiName); + contentData.add(apiName); contentText.add(apiData.getArgs()); contentData.add(apiData.getArgs()); @@ -159,13 +177,9 @@ public class ThreadAPIListTable extends DAApiListTableComposite { contentText.add(apiData.getReturn()); contentData.add(apiData.getReturn()); - String errMsg = ErrorCodeManager.getInatance().getErrorCode(apiData.getErrno()).name(); - if (null == errMsg) { - errMsg = "undefined error code"; - } contentText.add(errMsg); contentData.add(errMsg); - + DATableDataFormat tableData = new DATableDataFormat(apiData.getSeq()); tableData.setLogData(apiData); tableData.getData().addAll(contentData); @@ -184,14 +198,23 @@ public class ThreadAPIListTable extends DAApiListTableComposite { return input; } - private List selectAPIListFromDB(ThreadPageData data, int selectID) { + private List selectAPIListFromDB(ThreadPageData data, int selectID, + List filterList) { List returnList = new ArrayList(); if(null == data){ return returnList; } + + // add filter condition in query : PID, TID, Parameter, Return + String filterCondition = CommonConstants.EMPTY; + if (!filterList.isEmpty()) { + filterCondition = convertFilterProperty2WhereQuery(filterList); + } + ResultSet rs = null; if (data instanceof ThreadPageThreadData) { String query = String.format(ThreadAPIDBTable.SELECT_QUERY, selectID); + query += filterCondition; rs = SqlConnectionManager.executeQueryRS(query); if (null == rs) { Logger.debug("failed to query api data in thread API table"); @@ -199,6 +222,7 @@ public class ThreadAPIListTable extends DAApiListTableComposite { } } else if (data instanceof ThreadPageSyncData) { String query = String.format(SyncAPIDBTable.SELECT_QUERY, selectID); + query += filterCondition; rs = SqlConnectionManager.executeQueryRS(query); if (null == rs) { Logger.debug("failed to query api data in sync API table"); @@ -222,7 +246,7 @@ public class ThreadAPIListTable extends DAApiListTableComposite { return returnList; } - private List getSyncAPIOfNotInsert(int selectID) { + private List getSyncAPIOfNotInsert(int selectID, List filterList) { List returnList = new ArrayList(); List notInsertList = ThreadDataManager.getInstance() .getSyncDataMaker().getNotInsertSyncEventList(); @@ -230,7 +254,12 @@ public class ThreadAPIListTable extends DAApiListTableComposite { if (event.getSyncDataID() != selectID) { continue; } - returnList.add((SyncData) event.getContents()); + + // add filter condition in memory + SyncData probeData = (SyncData) event.getContents(); + if (filterInSyncData(filterList, probeData)) { + returnList.add(probeData); + } // else : data does not appear in the table } return returnList; } @@ -269,4 +298,152 @@ public class ThreadAPIListTable extends DAApiListTableComposite { } return pData; } + + @Override + public boolean[] getColumnVisibility() { + if (null == table) + return null; + + GridColumn[] columns = table.getColumns(); + int size = columns.length; + boolean[] columnsVisibility = new boolean[size]; + + // # column does not support filtering + columnsVisibility[0] = false; + + for (int i = 1; i < size; i++) { + columnsVisibility[i] = columns[i].getVisible(); + } + + return columnsVisibility; + } + + private boolean filterInSyncData(List filterList, ProbeCommonData apiData) { + for (int i = 0; i < filterList.size(); i++) { + FilterProperty prop = filterList.get(i); + String value = prop.getKeyWord().toLowerCase(); + switch(prop.getColumnIndex()) { + case 1: // Time + String time = Formatter.toTimeFormat(apiData.getTime()); + if (time.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 2: // PID + String pid = Integer.toString(apiData.getPid()); + if (pid.contains(value)) { + break; + } else { + return false; + } + case 3: // TID + String tid = Integer.toString(apiData.getTid()); + if (tid.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 4: // API name + String apiName = apiData.getApiName(); + if (apiName.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 5: // Parameter + String parameter = apiData.getArgs(); + if (parameter.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 6: // Return + String returnValue = apiData.getReturn(); + if (returnValue.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 7: // Error Code + String errMsg = ErrorCodeManager.getInatance().getErrorCode(apiData.getErrno()).name(); + if (errMsg.toLowerCase().contains(value)) { + break; + } else { + return false; + } + default: + Logger.warning("unsupported filter column : " + prop.getColumnIndex() + ", " + value); + return false; // unsupported filter column + } + } + return true; + } + + private boolean filterAfterDB(List filterList, String time, String apiName, String errMsg) { + // check for filter data of the excluded columns from the process of creating a filter query + for (int i = 0; i < filterList.size(); i++) { + FilterProperty prop = filterList.get(i); + String value = prop.getKeyWord().toLowerCase(); + switch (prop.getColumnIndex()) { + case 1: // Time + if (time.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 4: // API name + if (apiName.toLowerCase().contains(value)) { + break; + } else { + return false; + } + case 7: // Error Code + if (errMsg.toLowerCase().contains(value)) { + break; + } else { + return false; + } + default: + break; + } + } + return true; + } + + private String convertFilterProperty2WhereQuery(List filterList) { + String filterCondition = CommonConstants.EMPTY; + for (int i = 0; i < filterList.size(); i++) { + FilterProperty prop = filterList.get(i); + String queryPrefix = getFilteredColumnName(prop.getColumnIndex()); + if (queryPrefix != null) { + filterCondition += " and " + makeFilterWhereClause(queryPrefix, prop.getKeyWord()); + } + } + return filterCondition; + } + + // excluded columns : Time, API name, Error Code + @Override + protected String getFilteredColumnName(int index) { + String columnName = null; + switch(index) { + case 2: + columnName = DBConstants.DBCOLUMN_PID; + break; + case 3: + columnName = DBConstants.DBCOLUMN_TID; + break; + case 5: + columnName = addLowerOperation(DBConstants.DBCOLUMN_ARGUMENT); + break; + case 6: + columnName = addLowerOperation(DBConstants.DBCOLUMN_RETURN_VALUE); + break; + default: + break; + } + + return columnName; + } } \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListView.java index f21b9d7..990d678 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListView.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadAPIListView.java @@ -40,11 +40,11 @@ import org.tizen.dynamicanalyzer.ui.range.RangeDataManager; import org.tizen.dynamicanalyzer.ui.thread.type.ThreadPageData; import org.tizen.dynamicanalyzer.ui.timeline.TimelinePage; import org.tizen.dynamicanalyzer.ui.toolbar.Toolbar; +import org.tizen.dynamicanalyzer.ui.widgets.DAAdvancedViewComposite; import org.tizen.dynamicanalyzer.ui.widgets.table.TableColumnSizePackListener; -import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; import org.tizen.dynamicanalyzer.widgets.da.view.DAViewData; -public class ThreadAPIListView extends DAViewComposite { +public class ThreadAPIListView extends DAAdvancedViewComposite { private ThreadPageData data; private long analysisStartTime = 0; private long analysisEndTime = 0; @@ -73,7 +73,7 @@ public class ThreadAPIListView extends DAViewComposite { ThreadAPIListTable tableComp = null; public ThreadAPIListView(Composite parent, int style) { - super(parent, style, true); + super(parent, style, true, true); this.setLayout(new FillLayout()); setTitle(ThreadPageLabels.THREAD_API_LIST_VEIW_TITLE); @@ -90,6 +90,7 @@ public class ThreadAPIListView extends DAViewComposite { tableComp.setColumnSize(columnSizes); contents.addControlListener(new TableColumnSizePackListener(tableComp, columnSizes)); + setTable(tableComp); } @Override @@ -134,7 +135,6 @@ public class ThreadAPIListView extends DAViewComposite { if (vdata instanceof DASelectionData == false) { return; } - tableComp.clear(); DASelectionData data = (DASelectionData) vdata; ThreadPageData pageData; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/ThreadPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/ThreadChartView.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/ThreadChartView.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/TimelinePage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/TimelinePage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/calltrace/CallTraceTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/calltrace/CallTraceTable.java index f840c3a..475e080 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/calltrace/CallTraceTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/calltrace/CallTraceTable.java @@ -39,6 +39,7 @@ import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.TimelinePageLabels; import org.tizen.dynamicanalyzer.project.BinaryInfo; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/chart/UserCustomChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/chart/UserCustomChart.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/AddChartMenuComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/AddChartMenuComposite.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/TimelineConstants.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/TimelineConstants.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/logparser/CustomLogParser.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/logparser/CustomLogParser.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialog.java index eff2107..634cc18 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialog.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialog.java @@ -44,6 +44,7 @@ import org.eclipse.swt.widgets.Shell; import org.tizen.dynamicanalyzer.appearance.DesignConstants; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.TimelinePageLabels; import org.tizen.dynamicanalyzer.nl.WidgetLabels; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialogTableCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/uievent/UIEventListDialogTableCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/AboutDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/AboutDialog.java index 8f50128..ef595c6 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/AboutDialog.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/AboutDialog.java @@ -40,6 +40,8 @@ import org.eclipse.swt.events.DisposeEvent; import org.eclipse.swt.events.DisposeListener; import org.eclipse.swt.events.PaintEvent; import org.eclipse.swt.events.PaintListener; +import org.eclipse.swt.events.SelectionEvent; +import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.graphics.Image; import org.eclipse.swt.graphics.Rectangle; import org.eclipse.swt.layout.FormAttachment; @@ -47,9 +49,9 @@ import org.eclipse.swt.layout.FormData; import org.eclipse.swt.layout.FormLayout; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; +import org.eclipse.swt.widgets.Link; import org.eclipse.swt.widgets.Shell; import org.tizen.dynamicanalyzer.appearance.DesignConstants; -import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.path.PathManager; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; @@ -60,7 +62,6 @@ import org.tizen.dynamicanalyzer.resources.ImageResources; import org.tizen.dynamicanalyzer.shortcut.ShortCutManager; import org.tizen.dynamicanalyzer.util.CommonUtil; import org.tizen.dynamicanalyzer.util.Logger; -import org.tizen.dynamicanalyzer.util.WorkbenchUtil; import org.tizen.dynamicanalyzer.widgets.button.DACustomButton; import org.tizen.dynamicanalyzer.widgets.button.DACustomButtonClickEventListener; import org.tizen.dynamicanalyzer.widgets.da.base.DAButton; @@ -68,23 +69,19 @@ import org.tizen.dynamicanalyzer.widgets.da.base.DAMessageBox; public class AboutDialog extends DAMessageBox { private static boolean opened = false; - private DACustomButton licenseButton = null; private DACustomButton okButton = null; - private static String ideBuildVersionInfo = CommonConstants.EMPTY; - private static String daBuildVersionInfo = CommonConstants.EMPTY; - private static String daBuildTimeInfo = CommonConstants.EMPTY; - - private static String daVersionInfo = AnalyzerConstants.DA_VERSION; + private static String sdkBuildVersionInfo = CommonConstants.EMPTY; + private static String daBuildIDInfo = CommonConstants.EMPTY; private final Image iconImage = ImageResources.ABOUT_TIZEN_SDK; - final static String daAboutFilePath = PathManager.getWorkbenchPluginPath() + File.separator - + "about.mappings"; + final static String daAboutFilePath = PathManager.getWorkbenchPluginPath() + + File.separator + "about.mappings"; + + final static String sdkVersionFilePath = PathManager.TIZEN_SDK_INSTALL_PATH + + File.separator + "sdk.version"; - final static String sdkVersionFilePath = PathManager.TIZEN_SDK_INSTALL_PATH + File.separator - + "sdk.version"; - public AboutDialog(Shell parent) { super(parent); } @@ -97,16 +94,6 @@ public class AboutDialog extends DAMessageBox { } }; - private DACustomButtonClickEventListener licenseButtonListener = new DACustomButtonClickEventListener() { - - @Override - public void handleClickEvent(DACustomButton button) { - Shell shell = WorkbenchUtil.getWorkbenchWindow().getShell(); - LicenseDialog dialog = new LicenseDialog(shell, SWT.NONE); // FIXME - dialog.open(); - } - }; - protected boolean run() { if (opened) { return false; @@ -149,28 +136,21 @@ public class AboutDialog extends DAMessageBox { titleText.setText(AnalyzerLabels.ABOUT_DIALOG_TITLE); Label version = new Label(base, SWT.TRANSPARENT); - // String versionString = getVersion();// FIXME - version.setText(AnalyzerLabels.ABOUT_DIALOG_VERSION_TAB + ideBuildVersionInfo); + version.setText(AnalyzerLabels.ABOUT_DIALOG_VERSION_TAB + + sdkBuildVersionInfo); version.setBackground(ColorResources.DIALOG_BG_UPPER); version.setAlignment(SWT.LEFT); version.setForeground(ColorResources.DEFAULT_FONT_COLOR); version.setFont(FontResources.ABOUT_TEXT); - Label daVersion = new Label(base, SWT.TRANSPARENT); - daVersion.setText(AnalyzerLabels.ABOUT_DIALOG_DA_VERSION_TAB + daVersionInfo); - daVersion.setBackground(ColorResources.DIALOG_BG_UPPER); - daVersion.setAlignment(SWT.LEFT); - daVersion.setForeground(ColorResources.DEFAULT_FONT_COLOR); - daVersion.setFont(FontResources.ABOUT_TEXT); - - Label buildTime = new Label(base, SWT.TRANSPARENT); - // String buildTimeString = getBuildTime();// FIXME - buildTime.setText(AnalyzerLabels.ABOUT_DIALOG_BUILD_TIME_TAB + daBuildTimeInfo); - buildTime.setBackground(ColorResources.DIALOG_BG_UPPER); - buildTime.setAlignment(SWT.LEFT); - buildTime.setForeground(ColorResources.DEFAULT_FONT_COLOR); - buildTime.setFont(FontResources.ABOUT_TEXT); - + Label buildID = new Label(base, SWT.TRANSPARENT); + buildID.setText(AnalyzerLabels.ABOUT_DIALOG_BUILD_ID_TAB + + daBuildIDInfo); + buildID.setBackground(ColorResources.DIALOG_BG_UPPER); + buildID.setAlignment(SWT.LEFT); + buildID.setForeground(ColorResources.DEFAULT_FONT_COLOR); + buildID.setFont(FontResources.ABOUT_TEXT); + FormData labelData = new FormData(); labelData.left = new FormAttachment(0, 0); labelData.top = new FormAttachment(0, 0); @@ -187,7 +167,7 @@ public class AboutDialog extends DAMessageBox { titleText.setLayoutData(labelData); textPos += (17 + 15); - if(!ideBuildVersionInfo.equals(CommonConstants.EMPTY)){ + if (!sdkBuildVersionInfo.equals(CommonConstants.EMPTY)) { labelData = new FormData(); labelData.left = new FormAttachment(0, 155); labelData.right = new FormAttachment(100, 0); @@ -201,14 +181,41 @@ public class AboutDialog extends DAMessageBox { labelData.right = new FormAttachment(100, 0); labelData.top = new FormAttachment(0, textPos += 17); labelData.height = 17; - daVersion.setLayoutData(labelData); - - labelData = new FormData(); - labelData.left = new FormAttachment(0, 155); - labelData.right = new FormAttachment(100, 0); - labelData.top = new FormAttachment(0, textPos += 17); - labelData.height = 17; - buildTime.setLayoutData(labelData); + buildID.setLayoutData(labelData); + + Link visit = new Link(base, SWT.NONE); + baseData = new FormData(); + baseData.left = new FormAttachment(0, 155); + baseData.right = new FormAttachment(100, 0); + baseData.top = new FormAttachment(0, textPos += 51); + visit.setLayoutData(baseData); + visit.setText(AnalyzerLabels.ABOUT_DIALOG_VISIT + " " + + AnalyzerLabels.ABOUT_DIALOG_SITE_URL + ""); + visit.setForeground(ColorResources.DEFAULT_FONT_COLOR); + visit.setBackground(ColorResources.DIALOG_BG_UPPER); + visit.setFont(FontResources.ABOUT_TEXT); + visit.addSelectionListener(new SelectionListener() { + @Override + public void widgetDefaultSelected(SelectionEvent arg0) { + } + + @Override + public void widgetSelected(SelectionEvent arg0) { + try { + String url = AnalyzerLabels.ABOUT_DIALOG_SITE_URL; + if (CommonUtil.isWin()) { + org.eclipse.swt.program.Program.launch(url); + } else if (CommonUtil.isLinux()) { + Runtime.getRuntime().exec("xdg-open " + url); //$NON-NLS-1$ + } else if (CommonUtil.isMac()) { + Runtime.getRuntime().exec("/usr/bin/open " + url); //$NON-NLS-1$ + } + } catch (Throwable e) { + Logger.error("Failed to open developer site"); + return; + } + } + }); Composite buttonComp = new Composite(shell, SWT.NONE); buttonComp.setLayout(new FormLayout()); @@ -223,7 +230,8 @@ public class AboutDialog extends DAMessageBox { e.gc.setForeground(ColorResources.DIALOG_SUNKEN_1); e.gc.drawLine(rect.x, rect.y, rect.x + rect.width, rect.y); e.gc.setForeground(ColorResources.DIALOG_SUNKEN_2); - e.gc.drawLine(rect.x, rect.y + 1, rect.x + rect.width, rect.y + 1); + e.gc.drawLine(rect.x, rect.y + 1, rect.x + rect.width, + rect.y + 1); } }); @@ -246,38 +254,17 @@ public class AboutDialog extends DAMessageBox { okData.height = DesignConstants.DA_BUTTON_HEIGHT; okButton.setLayoutData(okData); - licenseButton = new DAButton(buttonComp, SWT.NONE); - licenseButton.addClickListener(licenseButtonListener); - licenseButton.setText(AnalyzerLabels.ABOUT_DIALOG_LICENSE); - licenseButton.setButtonFont(FontResources.DIALOG_BUTTON_FONT); - - FormData licenceData = new FormData(); - licenceData.top = new FormAttachment(0, 9); - licenceData.right = new FormAttachment(okButton, -10); - licenceData.width = DesignConstants.DA_BUTTON_WIDTH; - licenceData.height = DesignConstants.DA_BUTTON_HEIGHT; - licenseButton.setLayoutData(licenceData); - opened = true; ShortCutManager.getInstance().setEnabled(!opened); return true; } - public static void updateBuildInfoForMac() { - if (CommonUtil.isMac()) { - updateBuildInfo(); - } - } - public static void updateBuildInfo() { - if (ideBuildVersionInfo.equals(CommonConstants.EMPTY) - || daBuildTimeInfo.equals(CommonConstants.EMPTY)) { + if (sdkBuildVersionInfo.equals(CommonConstants.EMPTY) + || daBuildIDInfo.equals(CommonConstants.EMPTY)) { updateDABuildInfo(); - ideBuildVersionInfo = getSdkVersion(); - if (null != daBuildVersionInfo && daBuildVersionInfo.contains("RC")) {//$NON-NLS-1$ - return; - } + sdkBuildVersionInfo = getSdkVersion(); writeBuildInfoToAboutFile(); } } @@ -296,8 +283,9 @@ public class AboutDialog extends DAMessageBox { buffWriter = new BufferedWriter(fileWriter); printWriter = new PrintWriter(buffWriter); - printWriter.println("0" + CommonConstants.EQUAL + ideBuildVersionInfo);//$NON-NLS-1$ - printWriter.println("1" + CommonConstants.EQUAL + daBuildTimeInfo);//$NON-NLS-1$ + printWriter + .println("0" + CommonConstants.EQUAL + sdkBuildVersionInfo);//$NON-NLS-1$ + printWriter.println("1" + CommonConstants.EQUAL + daBuildIDInfo);//$NON-NLS-1$ printWriter.checkError(); } catch (IOException e) { Logger.exception(e); @@ -328,8 +316,7 @@ public class AboutDialog extends DAMessageBox { private static String getSdkVersion() { File file = new File(sdkVersionFilePath); if (!file.exists()) { - Logger.error( - "about dlg, not exists file : " + sdkVersionFilePath); + Logger.error("about dlg, not exists file : " + sdkVersionFilePath); return CommonConstants.EMPTY; } BufferedReader in = null; @@ -352,34 +339,6 @@ public class AboutDialog extends DAMessageBox { } return CommonConstants.EMPTY; } - - private static String getIDEVersion() { - File ideAboutFile = new File(PathManager.getIDEAboutFilePath()); - if (!ideAboutFile.exists()) { - Logger.error( - "about dlg, not exists file : " + PathManager.getIDEAboutFilePath()); - return CommonConstants.EMPTY; - } - BufferedReader in = null; - String content; - try { - in = new BufferedReader(new FileReader(ideAboutFile)); - while (null != (content = in.readLine())) { - String[] splitData = content.split("1="); //$NON-NLS-1$ - int size = splitData.length; - if (2 == size) { - return splitData[1]; - } - } - } catch (FileNotFoundException e) { - Logger.exception(e); - } catch (IOException e) { - Logger.exception(e); - } finally { - CommonUtil.tryClose(in); - } - return CommonConstants.EMPTY; - } private static void updateDABuildInfo() { String buildVersion; @@ -397,11 +356,11 @@ public class AboutDialog extends DAMessageBox { while (null != (content = in.readLine())) { buildVersion = parseBuildVersion(content); if (buildVersion != null) { - ideBuildVersionInfo = buildVersion; + sdkBuildVersionInfo = buildVersion; } buildTime = parseBuildTime(content); if (buildTime != null) { - daBuildTimeInfo = buildTime; + daBuildIDInfo = buildTime; } } } catch (FileNotFoundException e) { @@ -412,4 +371,5 @@ public class AboutDialog extends DAMessageBox { CommonUtil.tryClose(in); } } + } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/LicenseDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/LicenseDialog.java index 8b66c4b..7e2d80d 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/LicenseDialog.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/LicenseDialog.java @@ -63,7 +63,7 @@ public class LicenseDialog { private Shell shell = null; private DACustomButton okButton = null; - public LicenseDialog(Shell parent, int style) { + public LicenseDialog(Shell parent) { this.parent = parent; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/SaveAsDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/SaveAsDialog.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/Toolbar.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/Toolbar.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/OpenTraceDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/OpenTraceDialog.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/SaveFilesTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/SaveFilesTable.java index 0744fb3..812ec06 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/SaveFilesTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/opentrace/SaveFilesTable.java @@ -36,6 +36,7 @@ import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.Global; import org.tizen.dynamicanalyzer.common.path.PathManager; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; import org.tizen.dynamicanalyzer.project.Project; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/RepalyEditSaveDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/RepalyEditSaveDialog.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTable.java index d0b586b..7c33509 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTable.java @@ -39,6 +39,7 @@ import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.project.ImageInfo; import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTableCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditScreenshotTableCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditTable.java index ac21870..d3a439b 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/replayEditor/ReplayEditTable.java @@ -39,6 +39,7 @@ import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Event; import org.eclipse.swt.widgets.Listener; import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.ReplayEditLabels; import org.tizen.dynamicanalyzer.resources.FontResources; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialog.java index 9c1344e..1894cef 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialog.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialog.java @@ -57,15 +57,7 @@ import org.tizen.dynamicanalyzer.widgets.da.base.DAButton; import org.tizen.dynamicanalyzer.widgets.da.base.DAMessageBox; public class FeatureDialog extends DAMessageBox { - - public static final String ITEM_PARENT_FEATURE_NAME_ITEM = ", parent_feature_name_";//$NON-NLS-1$ - public static final String ITEM_ALL_CHECKED = ", item_all_checked ";//$NON-NLS-1$ - public static final String ITEM_PART_CHECKED = ", item_part_checked ";//$NON-NLS-1$ - public static final String FEATURE_OPTION_VALUE = ", feature_option_value ";//$NON-NLS-1$ - public static final String FEATURE_INVALID_VALUE = ", feature_invalid_value ";//$NON-NLS-1$ - private DATableComposite featuresTable = null; - private SettingDialogTemplatePage templatePage = null; int[] sortTypes = { AnalyzerConstants.SORT_TYPE_GRID }; private String[] columnNames = { ConfigureLabels.FEATURE_DIALOG_FEATURE_TABLE_COLUMN_NAME }; @@ -84,28 +76,23 @@ public class FeatureDialog extends DAMessageBox { @Override public void handleClickEvent(DACustomButton button) { // check feature change - SettingDialogManager setting = SettingDialogManager.getInstance(); Grid table = ((FeatureDialogFeaturesTable) featuresTable).getTable(); - if (setting.validInputText(table) && setting.changedFeaturesFromTableItemsList(table)) { + if (SettingDialogManager.INSTANCE.validInputText(table) && + SettingDialogManager.INSTANCE.changedFeaturesFromTableItemsList(table)) { // set custom template SettingDataManager.INSTANCE.getTarget(null).setSelectedTemplate( Template.TEMPLATE_CUSTOM); // apply selected feature - ((FeatureDialogFeaturesTable) featuresTable).setConfigurationDialogDataManager(); + SettingDialogManager.INSTANCE.setFeaturesValueFromTableItemsList(table); // update template view - templatePage.createTemplateTitleComposite(); - templatePage.createTemplateDescriptionComposite(); + result = Boolean.valueOf(true); } shell.dispose(); // close dialog } }; - public void setTemplatePage(SettingDialogTemplatePage templatePage) { - this.templatePage = templatePage; - } - private DACustomButtonClickEventListener cancelButtonListener = new DACustomButtonClickEventListener() { @Override @@ -137,9 +124,9 @@ public class FeatureDialog extends DAMessageBox { @Override public void mouseDown(MouseEvent e) { // check feature change - SettingDialogManager setting = SettingDialogManager.getInstance(); Grid table = ((FeatureDialogFeaturesTable) featuresTable).getTable(); - if (setting.validInputText(table) && setting.changedFeaturesFromTableItemsList(table)) { + if (SettingDialogManager.INSTANCE.validInputText(table) && + SettingDialogManager.INSTANCE.changedFeaturesFromTableItemsList(table)) { okButton.setButtonEnabled(true); } else { okButton.setButtonEnabled(false); @@ -252,7 +239,7 @@ public class FeatureDialog extends DAMessageBox { compData.right = new FormAttachment(100, 0); compData.bottom = new FormAttachment(100, 0); buttonContentsComp.setLayoutData(compData); - SettingDialogManager.getInstance().setFeatureDlg(this); + SettingDialogManager.INSTANCE.setFeatureDlg(this); buttonContentsComp.addPaintListener(new PaintListener() { @Override @@ -294,8 +281,4 @@ public class FeatureDialog extends DAMessageBox { shell.open(); return true; } - - public DATableComposite getFeatureTable() { - return this.featuresTable; - } } \ No newline at end of file diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTable.java index e782829..4231090 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTable.java @@ -38,6 +38,7 @@ import org.eclipse.swt.widgets.Event; import org.eclipse.swt.widgets.Listener; import org.tizen.dynamicanalyzer.common.DAState; import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.nl.ConfigureLabels; import org.tizen.dynamicanalyzer.resources.ColorResources; @@ -55,6 +56,13 @@ import org.tizen.dynamicanalyzer.widgets.tooltip.DACustomTooltip; public class FeatureDialogFeaturesTable extends DATreeComposite { private static final int tableTextOptionColumnIndex = 1; + + // row detail information + public static final String ITEM_PARENT_FEATURE_NAME_ITEM = ", parent_feature_name_";//$NON-NLS-1$ + public static final String ITEM_ALL_CHECKED = ", item_all_checked ";//$NON-NLS-1$ + public static final String ITEM_PART_CHECKED = ", item_part_checked ";//$NON-NLS-1$ + public static final String FEATURE_OPTION_VALUE = ", feature_option_value ";//$NON-NLS-1$ + public static final String FEATURE_INVALID_VALUE = ", feature_invalid_value ";//$NON-NLS-1$ public FeatureDialogFeaturesTable(Composite parent, int style) { super(parent, style); @@ -145,9 +153,7 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { /** * Creates an TreeInput Object for the feature. * - * @param feature - * feature information - * + * @param feature feature information * @return The resulting TreeInput object */ private TreeInput makeInput(FeatureData feature) { @@ -161,7 +167,7 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { // check selected feature : , item_all_checked if (target.isSelectedFeature(feature.getKey()) == true) { - optionColumn.append(FeatureDialog.ITEM_ALL_CHECKED); + optionColumn.append(ITEM_ALL_CHECKED); } else { optionColumn.append(CommonConstants.EMPTY); } @@ -169,14 +175,14 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { // check parent feature : , parent_feature_name_xxx if (feature.getParentIndex() > 0) { String parentFeatureName = Feature.getFeature(feature.getParentIndex()).getName(); - optionColumn.append(FeatureDialog.ITEM_PARENT_FEATURE_NAME_ITEM + parentFeatureName); + optionColumn.append(ITEM_PARENT_FEATURE_NAME_ITEM + parentFeatureName); } // check option feature : , feature_option_value "xxx" if (feature.getFeatureType() == SettingConstants.FEATURE_TYPE_DETAIL) { String optionText = getDetailFeatureOptionText(featureName); if (optionText != null) { - optionColumn.append(FeatureDialog.FEATURE_OPTION_VALUE + optionText); + optionColumn.append(FEATURE_OPTION_VALUE + optionText); } } @@ -190,15 +196,14 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { @Override public List makeTreeInput() { List output = new ArrayList(); - SettingDataManager setting = SettingDataManager.INSTANCE; - TargetData target = setting.getTarget(null); + TargetData target = SettingDataManager.INSTANCE.getTarget(null); List featureList = target.getAvailableFeatureList(); for (int i = 0; i < featureList.size(); i++) { FeatureData feature = featureList.get(i).getData(); // check exist current feature node - if (existTreeInput(output, feature.getFeatureName()) == false) { + if (!existTreeInput(output, feature.getFeatureName())) { // create current feature node TreeInput currentNode = makeInput(feature); @@ -209,7 +214,7 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { String parentFeatureName = Feature.getFeature(feature.getParentIndex()) .getName(); // check exist parent feature node - if (existTreeInput(output, parentFeatureName) == false) { + if (!existTreeInput(output, parentFeatureName)) { // create parent feature node TreeInput parentNode = makeInput(Feature.getFeature( feature.getParentIndex()).getData()); @@ -340,7 +345,7 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { int childUnCheckedCount = 0; for (int j = 0; j < treeData.getChildren().size(); j++) { if (treeData.getChildren().get(j).getText().get(1) - .contains(FeatureDialog.ITEM_ALL_CHECKED)) { + .contains(ITEM_ALL_CHECKED)) { childCheckedCount++; } else { childUnCheckedCount++; @@ -348,9 +353,9 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { } if (childCheckedCount > 0 && childUnCheckedCount == 0) { - setCheckStatus(treeData, FeatureDialog.ITEM_ALL_CHECKED); + setCheckStatus(treeData, ITEM_ALL_CHECKED); } else if (childCheckedCount > 0 && childUnCheckedCount > 0) { - setCheckStatus(treeData, FeatureDialog.ITEM_PART_CHECKED); + setCheckStatus(treeData, ITEM_PART_CHECKED); } else if (childCheckedCount == 0 && childUnCheckedCount > 0) { setCheckStatus(treeData, CommonConstants.EMPTY); } @@ -363,7 +368,7 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { private boolean isClickCheckBox(GridItem item, Event event) { String optionText = item.getText(tableTextOptionColumnIndex); int checkImgX = 0; - if (!optionText.contains(FeatureDialog.ITEM_PARENT_FEATURE_NAME_ITEM)) { + if (!optionText.contains(ITEM_PARENT_FEATURE_NAME_ITEM)) { checkImgX = 20; } else { checkImgX = 40; @@ -378,29 +383,26 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { // TODO:refactoring about the legacy code. private void updateCheckBox(GridItem item, Event event) { String optionText = item.getText(tableTextOptionColumnIndex); - if (optionText.contains(FeatureDialog.ITEM_PART_CHECKED)) { + if (optionText.contains(ITEM_PART_CHECKED)) { optionText = item.getText(tableTextOptionColumnIndex).replace( - FeatureDialog.ITEM_PART_CHECKED, CommonConstants.EMPTY); + ITEM_PART_CHECKED, CommonConstants.EMPTY); } - if (optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) { + if (optionText.contains(ITEM_ALL_CHECKED)) { optionText = item.getText(tableTextOptionColumnIndex).replace( - FeatureDialog.ITEM_ALL_CHECKED, CommonConstants.EMPTY); + ITEM_ALL_CHECKED, CommonConstants.EMPTY); } else { - optionText += FeatureDialog.ITEM_ALL_CHECKED; + optionText += ITEM_ALL_CHECKED; } item.setText(tableTextOptionColumnIndex, optionText); } - public void setConfigurationDialogDataManager() { - SettingDialogManager.getInstance().setFeaturesValueFromTableItemsList(table); - } // TODO:refactoring about the legacy code. private void updateChildCheckBoxByParent(GridItem item, Event event) { String featureName = item.getText(0); String optionText = item.getText(tableTextOptionColumnIndex); - if (!optionText.contains(FeatureDialog.ITEM_PARENT_FEATURE_NAME_ITEM)) { + if (!optionText.contains(ITEM_PARENT_FEATURE_NAME_ITEM)) { for (int i = 0; i < table.getItemCount(); i++) { FeatureData feature = Feature.getFeature(table.getItem(i).getText(0)).getData(); Feature parentFeature = Feature.getFeature(feature.getParentIndex()); @@ -408,8 +410,8 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { String parentFeatureName = parentFeature.getName(); if (featureName.equals(parentFeatureName)) { - if (optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) { - setCheckStatus(table.getItem(i), FeatureDialog.ITEM_ALL_CHECKED); + if (optionText.contains(ITEM_ALL_CHECKED)) { + setCheckStatus(table.getItem(i), ITEM_ALL_CHECKED); } else { setCheckStatus(table.getItem(i), CommonConstants.EMPTY); } @@ -437,10 +439,9 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { continue; } if (parentIndex > -1) { - FeatureData tableFeature = Feature.getFeature(table.getItem(i).getText(0)) - .getData(); + FeatureData tableFeature = Feature.getFeature(featureName).getData(); if (tableFeature.getParentIndex() == feature.getParentIndex()) { - if (table.getItem(i).getText(1).contains(FeatureDialog.ITEM_ALL_CHECKED)) { + if (table.getItem(i).getText(1).contains(ITEM_ALL_CHECKED)) { childCheckedCount++; } else { childUnCheckedCount++; @@ -449,9 +450,9 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { } } if (childCheckedCount > 0 && childUnCheckedCount == 0) { - setCheckStatus(table.getItem(parentIndex), FeatureDialog.ITEM_ALL_CHECKED); + setCheckStatus(table.getItem(parentIndex), ITEM_ALL_CHECKED); } else if (childCheckedCount > 0 && childUnCheckedCount > 0) { - setCheckStatus(table.getItem(parentIndex), FeatureDialog.ITEM_PART_CHECKED); + setCheckStatus(table.getItem(parentIndex), ITEM_PART_CHECKED); } else if (childCheckedCount == 0 && childUnCheckedCount > 0) { setCheckStatus(table.getItem(parentIndex), CommonConstants.EMPTY); } @@ -461,18 +462,18 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { // TODO:refactoring about the legacy code. private void setCheckStatus(TreeInput item, String status) { String optionText = item.getText().get(tableTextOptionColumnIndex); - if (optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) { + if (optionText.contains(ITEM_ALL_CHECKED)) { optionText = item.getText().get(tableTextOptionColumnIndex) - .replace(FeatureDialog.ITEM_ALL_CHECKED, CommonConstants.EMPTY); - } else if (optionText.contains(FeatureDialog.ITEM_PART_CHECKED)) { + .replace(ITEM_ALL_CHECKED, CommonConstants.EMPTY); + } else if (optionText.contains(ITEM_PART_CHECKED)) { optionText = item.getText().get(tableTextOptionColumnIndex) - .replace(FeatureDialog.ITEM_PART_CHECKED, CommonConstants.EMPTY); + .replace(ITEM_PART_CHECKED, CommonConstants.EMPTY); } - if (status.contains(FeatureDialog.ITEM_ALL_CHECKED)) { - optionText += FeatureDialog.ITEM_ALL_CHECKED; - } else if (status.contains(FeatureDialog.ITEM_PART_CHECKED)) { - optionText += FeatureDialog.ITEM_PART_CHECKED; + if (status.contains(ITEM_ALL_CHECKED)) { + optionText += ITEM_ALL_CHECKED; + } else if (status.contains(ITEM_PART_CHECKED)) { + optionText += ITEM_PART_CHECKED; } item.getText().set(tableTextOptionColumnIndex, optionText); } @@ -480,18 +481,18 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { // TODO:refactoring about the legacy code. private void setCheckStatus(GridItem item, String status) { String optionText = item.getText(tableTextOptionColumnIndex); - if (optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) { + if (optionText.contains(ITEM_ALL_CHECKED)) { optionText = item.getText(tableTextOptionColumnIndex).replace( - FeatureDialog.ITEM_ALL_CHECKED, CommonConstants.EMPTY); - } else if (optionText.contains(FeatureDialog.ITEM_PART_CHECKED)) { + ITEM_ALL_CHECKED, CommonConstants.EMPTY); + } else if (optionText.contains(ITEM_PART_CHECKED)) { optionText = item.getText(tableTextOptionColumnIndex).replace( - FeatureDialog.ITEM_PART_CHECKED, CommonConstants.EMPTY); + ITEM_PART_CHECKED, CommonConstants.EMPTY); } - if (status.contains(FeatureDialog.ITEM_ALL_CHECKED)) { - optionText += FeatureDialog.ITEM_ALL_CHECKED; - } else if (status.contains(FeatureDialog.ITEM_PART_CHECKED)) { - optionText += FeatureDialog.ITEM_PART_CHECKED; + if (status.contains(ITEM_ALL_CHECKED)) { + optionText += ITEM_ALL_CHECKED; + } else if (status.contains(ITEM_PART_CHECKED)) { + optionText += ITEM_PART_CHECKED; } item.setText(tableTextOptionColumnIndex, optionText); @@ -499,8 +500,8 @@ public class FeatureDialogFeaturesTable extends DATreeComposite { private boolean isCheckStatus(GridItem item) { String optionText = item.getText(tableTextOptionColumnIndex); - if (optionText.contains(FeatureDialog.ITEM_ALL_CHECKED) - || optionText.contains(FeatureDialog.ITEM_PART_CHECKED)) { + if (optionText.contains(ITEM_ALL_CHECKED) + || optionText.contains(ITEM_PART_CHECKED)) { return true; } return false; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableCellRenderer.java index d79cc40..2647784 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableCellRenderer.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableCellRenderer.java @@ -29,12 +29,12 @@ package org.tizen.dynamicanalyzer.ui.toolbar.setting; import org.eclipse.nebula.widgets.grid.Grid; import org.eclipse.nebula.widgets.grid.GridItem; -import org.eclipse.nebula.widgets.grid.internal.DefaultCellRenderer; import org.eclipse.swt.graphics.Color; import org.eclipse.swt.graphics.GC; import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.ui.widgets.table.DATableCellRenderer; -public class FeatureDialogFeaturesTreeTableCellRenderer extends DefaultCellRenderer { +public class FeatureDialogFeaturesTreeTableCellRenderer extends DATableCellRenderer { private static final int LEFT_MARGIN = 4; protected FeatureDialogFeaturesTreeTableToggleRenderer toggleRenderer; @@ -66,13 +66,11 @@ public class FeatureDialogFeaturesTreeTableCellRenderer extends DefaultCellRende toggleRenderer.setLocation(getBounds().x + x, (getBounds().height - toggleRenderer.getBounds().height) / 2 + getBounds().y); toggleRenderer.paint(gc, item); - } private void paintBackground(GC gc, GridItem item) { // background color Color color = null; - if (item.getLevel() == 0) { color = ColorResources.SETTING_TABLE_CONTENTS_PARENT; } else { diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableToggleRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableToggleRenderer.java index 5137992..0d67e95 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableToggleRenderer.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/FeatureDialogFeaturesTreeTableToggleRenderer.java @@ -27,7 +27,6 @@ package org.tizen.dynamicanalyzer.ui.toolbar.setting; -import org.eclipse.nebula.widgets.grid.AbstractRenderer; import org.eclipse.nebula.widgets.grid.Grid; import org.eclipse.nebula.widgets.grid.GridEditor; import org.eclipse.nebula.widgets.grid.GridItem; @@ -55,10 +54,11 @@ import org.tizen.dynamicanalyzer.resources.ImageResources; import org.tizen.dynamicanalyzer.setting.Feature; import org.tizen.dynamicanalyzer.setting.FeatureData; import org.tizen.dynamicanalyzer.setting.SettingConstants; +import org.tizen.dynamicanalyzer.ui.widgets.table.DATableToggleRenderer; import org.tizen.dynamicanalyzer.widgets.da.base.DATextBox; -public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRenderer { - static final int intevalSize = 15; +public class FeatureDialogFeaturesTreeTableToggleRenderer extends DATableToggleRenderer { + private static final int intevalSize = 15; private Grid table = null; // System detail widget @@ -114,8 +114,8 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender // draw checkBox image Image checkImg = null; - if (item.getText(1).contains(FeatureDialog.ITEM_ALL_CHECKED) - || item.getText(1).contains(FeatureDialog.ITEM_PART_CHECKED)) { + if (item.getText(1).contains(FeatureDialogFeaturesTable.ITEM_ALL_CHECKED) + || item.getText(1).contains(FeatureDialogFeaturesTable.ITEM_PART_CHECKED)) { checkImg = ImageResources.CHECKBOX_SELECTED; // } else if (item.getText(1).contains( // FeatureDialog.ITEM_PART_CHECKED)) { @@ -132,7 +132,7 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender // draw text : feature name gc.drawText(item.getText(), x, getBounds().y - 2, true); - } else { + } else { // child feature Rectangle r = ImageResources.TREE_OPEN.getBounds(); int offset = (getBounds().width - r.width) / 2; int x = getBounds().x + offset; @@ -143,9 +143,9 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender } else { // sub feature // draw checkBox image Image checkImg = null; - if (item.getText(1).contains(FeatureDialog.ITEM_ALL_CHECKED)) { + if (item.getText(1).contains(FeatureDialogFeaturesTable.ITEM_ALL_CHECKED)) { checkImg = ImageResources.CHECKBOX_SELECTED; - } else if (item.getText(1).contains(FeatureDialog.ITEM_PART_CHECKED)) { + } else if (item.getText(1).contains(FeatureDialogFeaturesTable.ITEM_PART_CHECKED)) { checkImg = ImageResources.CHECKBOX_SELECTED_PART; } else { checkImg = ImageResources.CHECKBOX_UNSELECTED; @@ -176,9 +176,6 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender .getText())) { updateSamplingDetails(item); } - - // check is running - checkRunningState(); } private void initSystemDetailWidget() { @@ -208,7 +205,6 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender data.width = 50; data.height = 13; systemTextBox.setLayoutData(data); - systemTextBox.setForeground(ColorResources.SETTING_COLOR); systemTextBox.setFont(FontResources.SETTING_DESCRIPTION_FONT); systemTextBox.getControl().addKeyListener(systemKeyListener); @@ -247,6 +243,7 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender } private void initSamplingDetailWidget() { + // composite detailSamplingComposit = new Composite(table, SWT.NONE); detailSamplingComposit.setLayout(new FormLayout()); detailSamplingComposit.setBackground(ColorResources.SETTING_TABLE_CONTENTS_CHILD); @@ -272,7 +269,6 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender data.width = 50; data.height = 13; samplingTextBox.setLayoutData(data); - samplingTextBox.setForeground(ColorResources.SETTING_COLOR); samplingTextBox.setFont(FontResources.SETTING_DESCRIPTION_FONT); samplingTextBox.getControl().addKeyListener(samplingKeyListener); @@ -308,17 +304,16 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender samplingInfo.setForeground(ColorResources.SETTING_WARNING_FONT_COLOR); samplingInfo.setFont(FontResources.SETTING_DESCRIPTION_FONT); samplingInfo.setBackground(ColorResources.SETTING_TABLE_CONTENTS_CHILD); - } private void updateSystemDetails(GridItem item) { // text box String text = getOptionText(item, ConfigureLabels.SAMPLING); - if ((null != text) && (text.equals(systemTextBox.getText()) == false)) { + if ((null != text) && (!text.equals(systemTextBox.getText()))) { systemTextBox.setText(text); } - if (isTableSelectedFeature(item.getParentItem().getText()) == true) { + if (isTableSelectedFeature(item.getParentItem().getText())) { systemTextBox.getControl().setEnabled(true); checkValidInputText(ConfigureLabels.FEATURE_DETAIL_VALUE_SYSTEM_SAMPLING_RATE, systemTextBox, systemInfo); @@ -327,6 +322,10 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender systemInfo.setText(CommonConstants.EMPTY); } + if (!DAState.isStartable()) { + systemTextBox.getControl().setEnabled(false); + } + systemEditor = new GridEditor(table); systemEditor.horizontalAlignment = SWT.LEFT; systemEditor.grabHorizontal = true; @@ -337,11 +336,11 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender private void updateSamplingDetails(GridItem item) { // text box String text = getOptionText(item, ConfigureLabels.SAMPLING); - if ((null != text) && (text.equals(samplingTextBox.getText()) == false)) { + if ((null != text) && (!text.equals(samplingTextBox.getText()))) { samplingTextBox.setText(text); } - if (isTableSelectedFeature(item.getParentItem().getText()) == true) { + if (isTableSelectedFeature(item.getParentItem().getText())) { samplingTextBox.getControl().setEnabled(true); checkValidInputText(ConfigureLabels.FEATURE_DETAIL_VALUE_FUNCTION_SAMPLING_RATE, samplingTextBox, samplingInfo); @@ -361,25 +360,13 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender detailSamplingComposit.layout(true); } - private void checkRunningState() { - if (!DAState.isStartable()) { - if (null != systemTextBox) { - systemTextBox.getControl().setEnabled(false); - } - - if (null != samplingTextBox) { - samplingTextBox.getControl().setEnabled(false); - } - } - } - private boolean isTableSelectedFeature(String featureName) { GridItem[] list = table.getItems(); for (int i = 0; i < list.length; i++) { if (featureName.equals(list[i].getText(0))) { String optionText = list[i].getText(1); - if (optionText.contains(FeatureDialog.ITEM_ALL_CHECKED) - || optionText.contains(FeatureDialog.ITEM_PART_CHECKED)) { + if (optionText.contains(FeatureDialogFeaturesTable.ITEM_ALL_CHECKED) + || optionText.contains(FeatureDialogFeaturesTable.ITEM_PART_CHECKED)) { return true; } else { return false; @@ -447,12 +434,12 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender private void updateInputText(GridItem item, boolean valid) { String optionText = item.getText(1); - if (optionText.contains(FeatureDialog.FEATURE_INVALID_VALUE)) { - optionText = item.getText(1).replace(FeatureDialog.FEATURE_INVALID_VALUE, + if (optionText.contains(FeatureDialogFeaturesTable.FEATURE_INVALID_VALUE)) { + optionText = item.getText(1).replace(FeatureDialogFeaturesTable.FEATURE_INVALID_VALUE, CommonConstants.EMPTY); } if (valid == false) { - optionText += FeatureDialog.FEATURE_INVALID_VALUE; + optionText += FeatureDialogFeaturesTable.FEATURE_INVALID_VALUE; } item.setText(1, optionText); } @@ -465,9 +452,6 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender boolean valid = checkValidInputText( ConfigureLabels.FEATURE_DETAIL_VALUE_SYSTEM_SAMPLING_RATE, systemTextBox, systemInfo); - if (valid) { - systemInfo.setText(CommonConstants.EMPTY); - } // update button state GridItem item = getGridItem(ConfigureLabels.FEATURE_DETAIL_VALUE_SYSTEM_SAMPLING_RATE); @@ -475,7 +459,7 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender setOptionText(item, ConfigureLabels.SAMPLING, systemTextBox.getText()); updateInputText(item, valid); - SettingDialogManager.getInstance().updateFeatureButtonStatus(table); + SettingDialogManager.INSTANCE.updateFeatureButtonStatus(table); } } @@ -492,9 +476,6 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender boolean valid = checkValidInputText( ConfigureLabels.FEATURE_DETAIL_VALUE_FUNCTION_SAMPLING_RATE, samplingTextBox, samplingInfo); - if (valid) { - samplingInfo.setText(CommonConstants.EMPTY); - } // update button state GridItem item = getGridItem(ConfigureLabels.FEATURE_DETAIL_VALUE_FUNCTION_SAMPLING_RATE); @@ -502,7 +483,7 @@ public class FeatureDialogFeaturesTreeTableToggleRenderer extends AbstractRender setOptionText(item, ConfigureLabels.SAMPLING, samplingTextBox.getText()); updateInputText(item, valid); - SettingDialogManager.getInstance().updateFeatureButtonStatus(table); + SettingDialogManager.INSTANCE.updateFeatureButtonStatus(table); } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialog.java index 2ee72ab..b8d4016 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialog.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialog.java @@ -153,7 +153,7 @@ public class SettingDialog extends DAMessageBox { return false; } IDECommunicator.setOpenWelcomeDlg(true); - shell.setSize(611, 520); + shell.setSize(631, 550); shell.setLayout(new FormLayout()); shell.setText(AnalyzerLabels.SETTING_TITLE); shell.setBackground(ColorResources.CONFIGURATION_TABLE_COVER_BACKGROUND_COLOR); @@ -208,8 +208,6 @@ public class SettingDialog extends DAMessageBox { templatesPage = new SettingDialogTemplatePage(tabView.getContentComposite(), SWT.NONE); tabView.addView(templatesPage, false); - SettingDialogManager.getInstance().setConfigDlg(this); - optionPage = new SettingDialogOptionPage(tabView.getContentComposite(), SWT.NONE); tabView.addView(optionPage, false); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogManager.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogManager.java index 62d1b31..47097e8 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogManager.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogManager.java @@ -36,30 +36,12 @@ import org.tizen.dynamicanalyzer.setting.FeatureValueData; import org.tizen.dynamicanalyzer.setting.SettingConstants; import org.tizen.dynamicanalyzer.setting.SettingDataManager; import org.tizen.dynamicanalyzer.setting.TargetData; -import org.tizen.dynamicanalyzer.widgets.da.base.DAMessageBox; -public class SettingDialogManager { +public enum SettingDialogManager { + INSTANCE; - private static SettingDialogManager instance = null; - - private DAMessageBox configDlg = null; private FeatureDialog featureDlg = null; - - public synchronized static SettingDialogManager getInstance() { - if (instance == null) { - instance = new SettingDialogManager(); - } - return instance; - } - - public void setConfigDlg(DAMessageBox configDlg) { - this.configDlg = configDlg; - } - - public DAMessageBox getConfigDlg() { - return configDlg; - } - + public FeatureDialog getFeatureDlg() { return featureDlg; } @@ -86,12 +68,12 @@ public class SettingDialogManager { String optionText = table.getItem(i).getText(1); Feature feature = Feature.getFeature(featureName); - if ((optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) - || (optionText.contains(FeatureDialog.ITEM_PART_CHECKED))) { + if ((optionText.contains(FeatureDialogFeaturesTable.ITEM_ALL_CHECKED)) + || (optionText.contains(FeatureDialogFeaturesTable.ITEM_PART_CHECKED))) { // check detail feature if (feature.getData().getFeatureType() == SettingConstants.FEATURE_TYPE_DETAIL) { - featureValue = addDetailFeature(table.getItem(i), target); + featureValue = addDetailFeature(table.getItem(i)); } else { // main, sub fearue featureValue = new FeatureValueData(feature); } @@ -104,9 +86,7 @@ public class SettingDialogManager { /** * Make sure that the feature has changed in the table. * - * @param table - * feature table - * + * @param table feature table * @return Whether the change of feature */ public boolean changedFeaturesFromTableItemsList(Grid table) { @@ -118,8 +98,8 @@ public class SettingDialogManager { String optionText = table.getItem(i).getText(1); Feature feature = Feature.getFeature(featureName); - if ((optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) - || (optionText.contains(FeatureDialog.ITEM_PART_CHECKED))) { + if ((optionText.contains(FeatureDialogFeaturesTable.ITEM_ALL_CHECKED)) + || (optionText.contains(FeatureDialogFeaturesTable.ITEM_PART_CHECKED))) { count++; // check detail feature @@ -145,9 +125,9 @@ public class SettingDialogManager { for (int i = 0; i < table.getItemCount(); i++) { String optionText = table.getItem(i).getText(1); - if ((optionText.contains(FeatureDialog.ITEM_ALL_CHECKED)) - || (optionText.contains(FeatureDialog.ITEM_PART_CHECKED))) { - if (optionText.contains(FeatureDialog.FEATURE_INVALID_VALUE)) { + if ((optionText.contains(FeatureDialogFeaturesTable.ITEM_ALL_CHECKED)) + || (optionText.contains(FeatureDialogFeaturesTable.ITEM_PART_CHECKED))) { + if (optionText.contains(FeatureDialogFeaturesTable.FEATURE_INVALID_VALUE)) { return false; } } @@ -155,7 +135,7 @@ public class SettingDialogManager { return true; } - private FeatureValueData addDetailFeature(GridItem item, TargetData target) { + private FeatureValueData addDetailFeature(GridItem item) { FeatureValueData featureValue = null; String featureName = item.getText(0); Feature feature = Feature.getFeature(featureName); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogOptionPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogOptionPage.java old mode 100755 new mode 100644 index 5a2f065..8f2d048 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogOptionPage.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogOptionPage.java @@ -284,7 +284,6 @@ public class SettingDialogOptionPage extends DAPageComposite { e.doit = e.text.matches("[0-9]*"); } }); - // label periodicallyTextBoxLabel = new Label(this, SWT.TRANSPARENT); @@ -402,8 +401,6 @@ public class SettingDialogOptionPage extends DAPageComposite { isValidInputValue = checkValidInputText(Feature.SCREENSHOT_PERIODICALLY, periodicallyTextBox, periodicallyInfo); if (isValidInputValue) { - periodicallyInfo.setText(CommonConstants.EMPTY); - SettingDataManager.INSTANCE.addOptionsSelectedFeature( Feature.SCREENSHOT_PERIODICALLY, Integer.parseInt(periodicallyTextBox.getText())); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogTemplatePage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogTemplatePage.java index ff38b58..f0b5608 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogTemplatePage.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/SettingDialogTemplatePage.java @@ -42,6 +42,7 @@ import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Event; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Listener; +import org.eclipse.swt.widgets.Shell; import org.tizen.dynamicanalyzer.common.DAState; import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; import org.tizen.dynamicanalyzer.nl.ConfigureLabels; @@ -53,6 +54,8 @@ import org.tizen.dynamicanalyzer.setting.SettingDataManager; import org.tizen.dynamicanalyzer.setting.TargetData; import org.tizen.dynamicanalyzer.setting.Template; import org.tizen.dynamicanalyzer.setting.TemplateData; +import org.tizen.dynamicanalyzer.util.CommonUtil; +import org.tizen.dynamicanalyzer.util.WorkbenchUtil; import org.tizen.dynamicanalyzer.widgets.button.DACustomButton; import org.tizen.dynamicanalyzer.widgets.button.DACustomButtonClickEventListener; import org.tizen.dynamicanalyzer.widgets.button.toggle.DACustomToggleButton; @@ -60,22 +63,24 @@ import org.tizen.dynamicanalyzer.widgets.button.toggle.DACustomToggleButtonGroup import org.tizen.dynamicanalyzer.widgets.da.base.DAButton; import org.tizen.dynamicanalyzer.widgets.da.view.DAPageComposite; -public class SettingDialogTemplatePage extends DAPageComposite { +public class SettingDialogTemplatePage extends DAPageComposite { private enum ProfileDisplayInfo { - PROFILE_NAME_MOBILE(0, ConfigureLabels.TARGET_NAME_MOBILE, ImageResources.TARGET_NAME_MOBILE), + PROFILE_NAME_MOBILE(0, ConfigureLabels.TARGET_NAME_MOBILE, + ImageResources.TARGET_NAME_MOBILE), PROFILE_NAME_TV(1, ConfigureLabels.TARGET_NAME_TV, ImageResources.TARGET_NAME_TV), - PROFILE_NAME_WEARABLE(2, ConfigureLabels.TARGET_NAME_WEARABLE, ImageResources.TARGET_NAME_WEARABLE); - + PROFILE_NAME_WEARABLE(2, ConfigureLabels.TARGET_NAME_WEARABLE, + ImageResources.TARGET_NAME_WEARABLE); + private int id = -1; private String displayName = null; private Image image = null; - + private ProfileDisplayInfo(int id, String displayName, Image image) { this.id = id; this.displayName = displayName; this.image = image; } - + public static Image getImage(String displayName) { ProfileDisplayInfo[] profiles = ProfileDisplayInfo.values(); for (ProfileDisplayInfo profile : profiles) { @@ -86,39 +91,41 @@ public class SettingDialogTemplatePage extends DAPageComposite { return null; } }; - + private enum TemplateDisplayInfo { - TEMPLATE_NAME_BOTTLENECK(0, ConfigureLabels.TEMPLATE_NAME_BOTTLENECK, + TEMPLATE_NAME_BOTTLENECK(0, ConfigureLabels.TEMPLATE_NAME_BOTTLENECK, ImageResources.TEMPLATE_BOTTLENECK_ANALYSIS), - TEMPLATE_NAME_MEMORY_LEAKS(1, ConfigureLabels.TEMPLATE_NAME_MEMORY_LEAKS, + TEMPLATE_NAME_MEMORY_LEAKS(1, ConfigureLabels.TEMPLATE_NAME_MEMORY_LEAKS, ImageResources.TEMPLATE_MEMORY_LEAK), - TEMPLATE_NAME_PROCESS_ACTIVITY(2, ConfigureLabels.TEMPLATE_NAME_PROCESS_ACTIVITY, + TEMPLATE_NAME_PROCESS_ACTIVITY(2, ConfigureLabels.TEMPLATE_NAME_PROCESS_ACTIVITY, ImageResources.TEMPLATE_PROCESS_ACTIVITY), - TEMPLATE_NAME_FILE(3, ConfigureLabels.TEMPLATE_NAME_FILE, + TEMPLATE_NAME_FILE(3, ConfigureLabels.TEMPLATE_NAME_FILE, ImageResources.TEMPLATE_FILE_ANALYSIS), - TEMPLATE_NAME_THREAD_ACTIVITY(4, ConfigureLabels.TEMPLATE_NAME_THREAD_ACTIVITY, + TEMPLATE_NAME_THREAD_ACTIVITY(4, ConfigureLabels.TEMPLATE_NAME_THREAD_ACTIVITY, ImageResources.TEMPLATE_THREAD_ACTIVITY_ANALYSIS), - TEMPLATE_NAME_WAIT_STATUS(5, ConfigureLabels.TEMPLATE_NAME_WAIT_STATUS, + TEMPLATE_NAME_WAIT_STATUS(5, ConfigureLabels.TEMPLATE_NAME_WAIT_STATUS, ImageResources.TEMPLATE_WAIT_STATUS_ANALYSIS), - TEMPLATE_NAME_NETWORK(6, ConfigureLabels.TEMPLATE_NAME_NETWORK, + TEMPLATE_NAME_NETWORK(6, ConfigureLabels.TEMPLATE_NAME_NETWORK, ImageResources.TEMPLATE_NETWORK_ANALYSIS), - TEMPLATE_NAME_OPEN_GL(7, ConfigureLabels.TEMPLATE_NAME_OPEN_GL, + TEMPLATE_NAME_OPEN_GL(7, ConfigureLabels.TEMPLATE_NAME_OPEN_GL, ImageResources.TEMPLATE_OPEN_GL_ANALYSIS), - TEMPLATE_NAME_ENERGY(8, ConfigureLabels.TEMPLATE_NAME_ENERGY, + TEMPLATE_NAME_ENERGY(8, ConfigureLabels.TEMPLATE_NAME_ENERGY, ImageResources.TEMPLATE_ENERGY), - TEMPLATE_NAME_CUSTOM(9, ConfigureLabels.TEMPLATE_NAME_CUSTOM, + TEMPLATE_NAME_HIERARCHY_VIEWER(9, ConfigureLabels.TEMPLATE_NAME_UI_HIERARCHY, + ImageResources.TEMPLATE_UI_HIERARCHY_ANALYSIS), + TEMPLATE_NAME_CUSTOM(10, ConfigureLabels.TEMPLATE_NAME_CUSTOM, ImageResources.TEMPLATE_CUSTOM); - + private int id = -1; private String displayName = null; private Image image = null; - + private TemplateDisplayInfo(int id, String displayName, Image image) { this.id = id; this.displayName = displayName; this.image = image; } - + public static Image getImage(String displayName) { TemplateDisplayInfo[] templates = TemplateDisplayInfo.values(); for (TemplateDisplayInfo template : templates) { @@ -144,30 +151,35 @@ public class SettingDialogTemplatePage extends DAPageComposite { // template description widget private Composite descriptionComp = null; - private Label icon = null; + private Label templateIcon = null; private Label templateNameLabel = null; private Label templateDescriptionLabel = null; + + // overhead widget private Label overheadLabel = null; private Label totalOverheadRange = null; private Label overheadDescriptionLabel = null; + private DACustomButton detailButton = null; - private SettingDialogTemplatePage me = null; - private DACustomButtonClickEventListener detailButtonListener = new DACustomButtonClickEventListener() { @Override public void handleClickEvent(DACustomButton button) { // show feature dialog - FeatureDialog dialog = new FeatureDialog(me.getShell()); - dialog.setTemplatePage(me); - dialog.open(); + Shell shell = WorkbenchUtil.getWorkbenchWindow().getShell(); + FeatureDialog dialog = new FeatureDialog(shell); + Object result = dialog.open(); + if (result != null) { + // update template page view + createTemplateTitleComposite(); + createTemplateDescriptionComposite(); + } } }; public SettingDialogTemplatePage(Composite parent, int style) { super(parent, style); - me = this; setTitle(AnalyzerLabels.COOLBAR_AREA_CONFIGURATION_FEATURES); this.setLayout(new FormLayout()); this.setBackground(ColorResources.CONFIGURATION_TABLE_COVER_BACKGROUND_COLOR); @@ -225,9 +237,9 @@ public class SettingDialogTemplatePage extends DAPageComposite { } private void initTemplateDescriptionWidget() { - if (null != icon) { - icon.dispose(); - icon = null; + if (null != templateIcon) { + templateIcon.dispose(); + templateIcon = null; } if (null != templateNameLabel) { @@ -306,7 +318,7 @@ public class SettingDialogTemplatePage extends DAPageComposite { compData.top = new FormAttachment(0, 41); compData.left = new FormAttachment(0, 6); compData.width = 86; - compData.height = 373; + compData.height = 403; targetComp.setLayoutData(compData); targetComp.setBackground(ColorResources.WHITE); @@ -383,7 +395,7 @@ public class SettingDialogTemplatePage extends DAPageComposite { TargetData target = entry.getValue(); DACustomToggleButton toggle = createToggleButton(targetInputComposite, - ProfileDisplayInfo.getImage(target.getTargetName()), imagePoint, + ProfileDisplayInfo.getImage(target.getTargetName()), imagePoint, target.getTargetName(), fontPoint, 76, 76, topPosition, leftPosition); targetGroup.addToggleButton(toggle); @@ -414,6 +426,9 @@ public class SettingDialogTemplatePage extends DAPageComposite { } } targetComp.layout(true); + targetInputComposite.layout(); + targetScrolledComposite.setMinSize(targetInputComposite.computeSize(SWT.DEFAULT, + SWT.DEFAULT)); if (!DAState.isStartable()) { targetComp.setEnabled(false); @@ -428,9 +443,9 @@ public class SettingDialogTemplatePage extends DAPageComposite { descriptionComp = new Composite(this, SWT.NONE); descriptionComp.setLayout(new FormLayout()); FormData compData = new FormData(); - compData.top = new FormAttachment(0, 235); + compData.top = new FormAttachment(0, 265); compData.left = new FormAttachment(0, 98); - compData.width = 504; + compData.width = 524; compData.height = 179; descriptionComp.setLayoutData(compData); descriptionComp.setBackground(ColorResources.WHITE); @@ -453,20 +468,19 @@ public class SettingDialogTemplatePage extends DAPageComposite { }); } - SettingDataManager setting = SettingDataManager.INSTANCE; - TargetData target = setting.getTarget(null); + TargetData target = SettingDataManager.INSTANCE.getTarget(null); TemplateData template = target.getSelectedTemplate().getData(); // image - icon = new Label(descriptionComp, SWT.TRANSPARENT); - icon.setImage(TemplateDisplayInfo.getImage(template.getTemplateName())); + templateIcon = new Label(descriptionComp, SWT.TRANSPARENT); + templateIcon.setImage(TemplateDisplayInfo.getImage(template.getTemplateName())); FormData data = new FormData(); data.left = new FormAttachment(0, 21); data.top = new FormAttachment(0, 16); data.width = 40; data.height = 40; - icon.setLayoutData(data); - icon.setBackground(ColorResources.WHITE); + templateIcon.setLayoutData(data); + templateIcon.setBackground(ColorResources.WHITE); // label : templateName templateNameLabel = new Label(descriptionComp, SWT.TRANSPARENT); @@ -573,8 +587,8 @@ public class SettingDialogTemplatePage extends DAPageComposite { FormData compData = new FormData(); compData.top = new FormAttachment(0, 41); compData.left = new FormAttachment(0, 98); - compData.width = 504; - compData.height = 188; + compData.width = 524; + compData.height = 218; templateComp.setLayoutData(compData); templateComp.setBackground(ColorResources.WHITE); @@ -590,7 +604,7 @@ public class SettingDialogTemplatePage extends DAPageComposite { e.gc.drawLine(0, 22, rect.width - 1, 22); e.gc.setBackground(ColorResources.SETTING_TITLE_BACKGROUND); - e.gc.fillRectangle(1, 1, 502, 21); + e.gc.fillRectangle(1, 1, 522, 21); } }); @@ -643,8 +657,13 @@ public class SettingDialogTemplatePage extends DAPageComposite { DACustomToggleButtonGroup targetGroup = new DACustomToggleButtonGroup(); Point imagePoint = new Point(23, 8); Point fontPoint = new Point(-1, 60); + int defaultLeftPosition = 21; // linux, mac + if (CommonUtil.isWin()) { + defaultLeftPosition = 13; + } + int topPosition = 4; - int leftPosition = 13; + int leftPosition = defaultLeftPosition; TargetData target = SettingDataManager.INSTANCE.getTarget(selectedTarget); Template selectedTemplate = target.getSelectedTemplate(); @@ -664,12 +683,11 @@ public class SettingDialogTemplatePage extends DAPageComposite { DACustomToggleButton toggleButton = (DACustomToggleButton) event.widget; if (toggleButton.isToggled()) { // set select template - SettingDataManager setting = SettingDataManager.INSTANCE; - TargetData target = setting.getTarget(null); + TargetData target = SettingDataManager.INSTANCE.getTarget(null); String preSelectedTemplate = target.getSelectedTemplate().getName(); - // TODO : redefine custom template usage - if (preSelectedTemplate.equals(toggleButton.getText()) == false) { + // template change + if (!preSelectedTemplate.equals(toggleButton.getText())) { Template template = Template.getTemplate(toggleButton.getText()); target.setSelectedTemplate(template); target.changeSelectedFeatureList(template); @@ -685,7 +703,7 @@ public class SettingDialogTemplatePage extends DAPageComposite { if (leftPosition + 96 < 480) { leftPosition += 96; } else { - leftPosition = 13; + leftPosition = defaultLeftPosition; topPosition += 79; } @@ -696,9 +714,11 @@ public class SettingDialogTemplatePage extends DAPageComposite { } templateComp.layout(true); + inputComposite.layout(); + scrolledComposite.setMinSize(inputComposite.computeSize(SWT.DEFAULT, SWT.DEFAULT)); if (!DAState.isStartable()) { templateComp.setEnabled(false); } } -} \ No newline at end of file +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/WelcomeDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/WelcomeDialog.java index 86de8a0..5c88786 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/WelcomeDialog.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/toolbar/setting/WelcomeDialog.java @@ -165,7 +165,6 @@ public class WelcomeDialog extends DAMessageBox { compData.right = new FormAttachment(100, 0); compData.bottom = new FormAttachment(100, 0); templatesPage.setLayoutData(compData); - SettingDialogManager.getInstance().setConfigDlg(this); // button composite Composite buttonContentsComp = new Composite(shell, SWT.NONE); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/UIPage.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/UIPage.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/control/UIControlListTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/control/UIControlListTable.java index a0e0b07..0fcac67 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/control/UIControlListTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/control/UIControlListTable.java @@ -44,6 +44,7 @@ import org.eclipse.swt.widgets.Listener; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.project.ImageInfo; import org.tizen.dynamicanalyzer.swap.model.data.ControlData; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/profiling/UIFunctionProfilingTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/profiling/UIFunctionProfilingTable.java index 30b62d6..3f9d1e1 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/profiling/UIFunctionProfilingTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/profiling/UIFunctionProfilingTable.java @@ -48,6 +48,7 @@ import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.model.ColumnData; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.nl.UserInterfacePageLabels; import org.tizen.dynamicanalyzer.ui.summary.profiling.ProfilingData; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/scene/UISceneListTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/scene/UISceneListTable.java index c21b276..5d24c52 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/scene/UISceneListTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/userinterface/scene/UISceneListTable.java @@ -38,6 +38,7 @@ import org.tizen.dynamicanalyzer.common.AnalyzerConstants; import org.tizen.dynamicanalyzer.common.AnalyzerManager; import org.tizen.dynamicanalyzer.common.DASelectionData; import org.tizen.dynamicanalyzer.common.Global; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.project.ImageInfo; import org.tizen.dynamicanalyzer.swap.model.data.SceneData; diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedPopupMenu.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedPopupMenu.java new file mode 100644 index 0000000..8b37ec7 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedPopupMenu.java @@ -0,0 +1,163 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Seokgil Kang + * Juyoung Kim + * WooJin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.ui.widgets; + +import org.eclipse.swt.events.MouseEvent; +import org.eclipse.swt.events.MouseListener; +import org.eclipse.swt.events.ShellEvent; +import org.eclipse.swt.events.ShellListener; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Display; +import org.eclipse.swt.widgets.Shell; +import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; +import org.tizen.dynamicanalyzer.resources.FontResources; +import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; +import org.tizen.dynamicanalyzer.util.WorkbenchUtil; +import org.tizen.dynamicanalyzer.widgets.popupMenu.DAPopupMenu; +import org.tizen.dynamicanalyzer.widgets.popupMenu.DAPopupMenuItem; +import org.tizen.dynamicanalyzer.widgets.popupMenu.DAPopupMenuListener; + +public class DAAdvancedPopupMenu extends DAPopupMenu { + public static final int advancedMenuButtonSize = 16; + public static final int advancedMenuButtonOffset = 3; + public static final int advancedMenuWidthOffset = 87; + public static final int advancedMenuHeightOffset = 5; + private DATableComposite ownTable = null; + + public enum ADVANCED_MENU_ITEM { + SEARCH(0, AnalyzerLabels.ADVANCED_MENU_SEARCH), + FILTER(1, AnalyzerLabels.ADVANCED_MENU_FILTER); + + public final int index; + public final String name; + + ADVANCED_MENU_ITEM(int index, String name) { + this.index = index; + this.name = name; + } + } + + public DAAdvancedPopupMenu(Composite parent) { + super(parent); + setFont(FontResources.CONTEXT_MENU_ITEM_FONT); + setDefaultMenuItems(); + } + + public void setTable(DATableComposite table) { + ownTable = table; + } + + private void setDefaultMenuItems() { + DAPopupMenuItem searchItem = new DAPopupMenuItem(this); + searchItem.setText(ADVANCED_MENU_ITEM.SEARCH.name); + searchItem.addListener(new DAPopupMenuListener() { + @Override + public void widgetSelected(DAPopupMenuItem menuItem) { + Display.getDefault().asyncExec(new Runnable() { + @Override + public void run() { + Shell shell = WorkbenchUtil.getWorkbenchWindow() + .getShell(); + FindDialog findDialog = new FindDialog(shell, ownTable); + findDialog.open(); + } + }); + } + }); + + DAPopupMenuItem filterItem = new DAPopupMenuItem(this); + filterItem.setText(ADVANCED_MENU_ITEM.FILTER.name); + filterItem.addListener(new DAPopupMenuListener() { + @Override + public void widgetSelected(DAPopupMenuItem menuItem) { + Display.getDefault().asyncExec(new Runnable() { + @Override + public void run() { + Shell shell = WorkbenchUtil.getWorkbenchWindow() + .getShell(); +// FilterDialog filterDialog = new FilterDialog(shell, me, ownTable, -1); + FilterDialog filterDialog = new FilterDialog(shell, ownTable, -1); + filterDialog.open(); + } + }); + } + }); + } + + @Override + public void setMouseListener() { + getParent().getShell().addShellListener(new ShellListener() { + + @Override + public void shellIconified(ShellEvent e) { + closeChild(); + } + + @Override + public void shellDeiconified(ShellEvent e) { + } + + @Override + public void shellDeactivated(ShellEvent e) { + } + + @Override + public void shellClosed(ShellEvent e) { + closeChild(); + } + + @Override + public void shellActivated(ShellEvent e) { + } + }); + + getParent().addMouseListener(new MouseListener() { + + @Override + public void mouseDoubleClick(MouseEvent e) { + } + + @Override + public void mouseDown(MouseEvent e) { + switch (e.button) { + case 1: { // left button of mouse + closeParent(); + break; + } + default: { + break; + } + } + } + + @Override + public void mouseUp(MouseEvent e) { + } + }); + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedTabComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedTabComposite.java new file mode 100644 index 0000000..6657120 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedTabComposite.java @@ -0,0 +1,113 @@ +package org.tizen.dynamicanalyzer.ui.widgets; + +import java.util.List; + +import org.eclipse.swt.SWT; +import org.eclipse.swt.graphics.Point; +import org.eclipse.swt.graphics.Rectangle; + +import org.eclipse.swt.events.PaintEvent; +import org.eclipse.swt.events.PaintListener; +import org.eclipse.swt.graphics.Image; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Event; +import org.eclipse.swt.widgets.Listener; +import org.tizen.dynamicanalyzer.resources.ImageResources; +import org.tizen.dynamicanalyzer.util.Logger; +import org.tizen.dynamicanalyzer.widgets.da.view.DABaseComposite; +import org.tizen.dynamicanalyzer.widgets.da.view.DATabComposite; + +public class DAAdvancedTabComposite extends DATabComposite { + private DAAdvancedPopupMenu advancedMenu = null; + + public DAAdvancedTabComposite(Composite parent, int style) { + super(parent, style); + setAdvancedFeature(); + } + + public DAAdvancedTabComposite(Composite parent, int style, boolean istoplevel) { + super(parent, style, istoplevel); + setAdvancedFeature(); + } + + private void setAdvancedFeature() { + advancedMenu = new DAAdvancedPopupMenu(contentsComposite); + + tabComposite.addPaintListener(tabCompositePaintListener); + tabComposite.addListener(SWT.MouseUp, advancedMenuButtonMouseUpListener); + } + + private PaintListener tabCompositePaintListener = new PaintListener() { + + @Override + public void paintControl(PaintEvent e) { + Composite comp = (Composite) e.widget; + Rectangle rect = comp.getClientArea(); + e.gc.drawImage( + ImageResources.ADVANCED_MENU_BUTTON_NORMAL, + rect.width + - (DAAdvancedPopupMenu.advancedMenuButtonSize + DAAdvancedPopupMenu.advancedMenuButtonOffset), + DAAdvancedPopupMenu.advancedMenuButtonOffset); + } + }; + + private Listener advancedMenuButtonMouseUpListener = new Listener() { + + @Override + public void handleEvent(Event event) { + Rectangle bounds = tabComposite.getBounds(); + int width = bounds.width; + // This part is same as the DAAdvancedViewComposite. + if (event.x < width - DAAdvancedPopupMenu.advancedMenuButtonSize + || event.x > width - DAAdvancedPopupMenu.advancedMenuButtonOffset * 2) { + return; + } + + // 1 means left button of mouse was clicked + if (event.button == 1) { + Point loc = getLocation(); + Point p = contentsComposite.toDisplay(loc); + int x = 0, y = 0; + x = p.x - loc.x + contentsComposite.getBounds().width + - DAAdvancedPopupMenu.advancedMenuWidthOffset; + y = p.y - loc.y; + + setPopupMenu(); + advancedMenu.open(advancedMenu.getTopShell(), x, y); + } + } + }; + + private void setPopupMenu() { + DABaseComposite baseComp = getTopComposite(); + if (baseComp instanceof DAAdvancedViewComposite) { + clearPopupMenuItemsEnableSetting(); + + DAAdvancedViewComposite comp = (DAAdvancedViewComposite) baseComp; + // Register DATableComposite in the DAAdvancedViewComposite + // to the FilterDialog + advancedMenu.setTable(comp.getTable()); + + // Set Advanced-Menu settings of + // the DAAdvancedViewComposite(selected view of the tab composite) + // to the Advanced-Menu of the DAAdvanceTabComposite + List disableMenuIndexes = comp.getDisabledMenuIndexes(); + if (disableMenuIndexes == null || disableMenuIndexes.isEmpty()) + return; + for (int i = 0; i < disableMenuIndexes.size(); i++) { + advancedMenu.getItem(disableMenuIndexes.get(i)).setEnabled(false); + } + } else { + Logger.debug("This view is not DAAdvancedViewComposite !!"); + for (int i = 0; i < advancedMenu.getItems().size(); i++) { + advancedMenu.getItems().get(i).setEnabled(false); + } + } + } + + private void clearPopupMenuItemsEnableSetting() { + for (int i = 0; i < advancedMenu.getItems().size(); i++) { + advancedMenu.getItems().get(i).setEnabled(true); + } + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedViewComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedViewComposite.java new file mode 100644 index 0000000..ac4b3c4 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/DAAdvancedViewComposite.java @@ -0,0 +1,232 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Seokgil Kang + * Juyoung Kim + * WooJin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.ui.widgets; + +import java.util.ArrayList; +import java.util.List; + +import org.eclipse.swt.SWT; +import org.eclipse.swt.events.PaintEvent; +import org.eclipse.swt.events.PaintListener; +import org.eclipse.swt.graphics.GC; +import org.eclipse.swt.graphics.Point; +import org.eclipse.swt.graphics.Rectangle; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Event; +import org.eclipse.swt.widgets.Listener; +import org.tizen.dynamicanalyzer.resources.ImageResources; +import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; +import org.tizen.dynamicanalyzer.util.Logger; +import org.tizen.dynamicanalyzer.widgets.da.view.DAViewComposite; +import org.tizen.dynamicanalyzer.widgets.popupMenu.DAPopupMenuItem; +import org.tizen.dynamicanalyzer.widgets.popupMenu.DAPopupMenuListener; + +public class DAAdvancedViewComposite extends DAViewComposite { + private DAAdvancedPopupMenu advancedMenu = null; + +// private boolean isPopupOpen = false; + + protected DATableComposite ownTable = null; +// private DAAdvancedViewComposite me = null; + + public DAAdvancedViewComposite(Composite parent, int style, boolean titleVisibility, + boolean advancedButtonActivation) { + super(parent, style, titleVisibility); + + contentArea = getContentArea(); + advancedMenu = new DAAdvancedPopupMenu(contentArea); +// createAdvancedMenu(); + + if (titleVisibility) { + if (advancedButtonActivation) { + titleBar = getTitleArea(); + titleBar.addPaintListener(advancedMenuButtonPaintListener); + titleBar.addListener(SWT.MouseUp, advancedMenuButtonMouseUpListener); + } + } + } + + /** + * Returns a list of Integers which are indexes of the disabled menu items + * in the advanced menu. + * + * Note : used only in the DAAdvancedTabComposite + * + * @return the disabled indexes + */ + public List getDisabledMenuIndexes() { + List disabledIndexes = new ArrayList(); + for (int i = 0; i < advancedMenu.getItems().size(); i++) { + if (!advancedMenu.getItem(i).isEnabled()) + disabledIndexes.add(i); + } + return disabledIndexes; + } + + /** + * Set the table object to apply a filter feature. + * + * @param table + * table object to apply a filter feature + */ + protected void setTable(DATableComposite table) { + if (table == null) { + Logger.error("table object is null !!"); + } else { + ownTable = table; + advancedMenu.setTable(table); + } + } + + /** + * Get the table object set on the this view. + * + * Note : used only in the DAAdvancedTabComposite + * + * @return table object to apply a filter feature + */ + public DATableComposite getTable() { + return ownTable; + } + + /** + * When the table data is updated by updateView() instead of updateTable(), + * below function(setView()) must be called. + * + * Note : It currently used only in the CallstackView class. + * + * @param view + * view object for registration + */ +// protected void setView(DAAdvancedViewComposite view) { +// me = view; +// } + + /** + * Adds a menu item to the advanced menu. + * + * @param itemName + * menu item name + * @param eventListener + * the listener which should be notified when the receiver is selected + */ + protected void addAdvancedMenuItem(String itemName, DAPopupMenuListener eventListener) { + DAPopupMenuItem searchItem = new DAPopupMenuItem(advancedMenu); + searchItem.setText(itemName); + searchItem.addListener(eventListener); + } + + /** + * Disables a menu item that corresponds to the index. + * + * @param itemIndex + * index of the menu item to disable + */ + protected void disableAdvancedMenuItem(int itemIndex) { + DAPopupMenuItem item = advancedMenu.getItem(itemIndex); + if (item != null) { + item.setEnabled(false); + } else { + Logger.debug("Wrong menu index !!"); + } + } + + private PaintListener advancedMenuButtonPaintListener = new PaintListener() { + + @Override + public void paintControl(PaintEvent e) { + GC gc = e.gc; + + Rectangle bounds = titleBar.getBounds(); + int width = bounds.width; + gc.drawImage(ImageResources.ADVANCED_MENU_BUTTON_NORMAL, + width + - (DAAdvancedPopupMenu.advancedMenuButtonSize + DAAdvancedPopupMenu.advancedMenuButtonOffset), + DAAdvancedPopupMenu.advancedMenuButtonOffset); + } + }; + + private Listener advancedMenuButtonMouseUpListener = new Listener() { + + @Override + public void handleEvent(Event event) { + Rectangle bounds = titleBar.getBounds(); + int width = bounds.width; + /** + * What we called the 'Advanced menu button', actually not a button, is an image. + * Therefore, when a user clicks the correct image (drop down image), the 'Advanced menu button' works. + * This part is a process for finding the 'drop down image'. + * I set the distance between the 'ImageResources.ADVANCED_MENU_BUTTON_NORMAL' + * and the 'drop down image' as a 'DAAdvancedPopupMenu.advancedMenuButtonOffset'. + * (see table filtering design guide - title layout) + */ + if (event.x < width - DAAdvancedPopupMenu.advancedMenuButtonSize + || event.x > width - DAAdvancedPopupMenu.advancedMenuButtonOffset * 2) { + return; + } + + // 1 means left button of mouse was clicked + if (event.button == 1) { + // TODO : think about how to display the advanced menu +// if (!isPopupOpen) { +// Point p = contentArea.toDisplay(getLocation()); +// advancedMenu.open(advancedMenu.getTopShell(), +// p.x + contentArea.getBounds().width - advancedMenuWidthOffset, +// p.y - advancedMenuHeightOffset); +// isPopupOpen = true; +// } else { +// if (advancedMenu.getTopShell() == null) { // advancedMenu was closed by timer +// Point p = contentArea.toDisplay(getLocation()); +// advancedMenu.open(advancedMenu.getTopShell(), +// p.x + contentArea.getBounds().width - advancedMenuWidthOffset, +// p.y - advancedMenuHeightOffset); +// isPopupOpen = true; +// } else { +// isPopupOpen = false; +// } +// } + +// if (contentArea.getShell() != null && !contentArea.getShell().isDisposed()) { + + // calculate position of advanced popup menu + Point loc = getLocation(); + Point p = contentArea.toDisplay(loc); + int x = 0, y = 0; + x = p.x - loc.x + contentArea.getBounds().width + - DAAdvancedPopupMenu.advancedMenuWidthOffset; + y = p.y - loc.y - DAAdvancedPopupMenu.advancedMenuHeightOffset; + + advancedMenu.open(advancedMenu.getTopShell(), x, y); + +// } else { +// contentArea.getShell().dispose(); +// } + } + } + }; +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterDialog.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterDialog.java new file mode 100644 index 0000000..a1b9891 --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterDialog.java @@ -0,0 +1,553 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Seokgil Kang + * Juyoung Kim + * WooJin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.ui.widgets; + +import java.util.ArrayList; +import java.util.List; + +import org.eclipse.swt.SWT; +import org.eclipse.swt.custom.ScrolledComposite; +import org.eclipse.swt.events.PaintEvent; +import org.eclipse.swt.events.PaintListener; +import org.eclipse.swt.events.ShellAdapter; +import org.eclipse.swt.events.ShellEvent; +import org.eclipse.swt.events.ShellListener; +import org.eclipse.swt.graphics.GC; +import org.eclipse.swt.graphics.Rectangle; +import org.eclipse.swt.layout.FormAttachment; +import org.eclipse.swt.layout.FormData; +import org.eclipse.swt.layout.FormLayout; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Event; +import org.eclipse.swt.widgets.Listener; +import org.eclipse.swt.widgets.Shell; +import org.tizen.dynamicanalyzer.constant.CommonConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; +import org.tizen.dynamicanalyzer.nl.AnalyzerLabels; +import org.tizen.dynamicanalyzer.nl.WidgetLabels; +import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.resources.ImageResources; +import org.tizen.dynamicanalyzer.ui.widgets.table.DATableComposite; +import org.tizen.dynamicanalyzer.ui.widgets.table.DATreeComposite; +import org.tizen.dynamicanalyzer.ui.widgets.table.DAWindowingTableComposite; +import org.tizen.dynamicanalyzer.util.Logger; +import org.tizen.dynamicanalyzer.widgets.button.DACustomButton; +import org.tizen.dynamicanalyzer.widgets.button.DACustomButtonClickEventListener; +import org.tizen.dynamicanalyzer.widgets.combo.DACustomCombo; +import org.tizen.dynamicanalyzer.widgets.combo.DACustomComboSelectionListener; +import org.tizen.dynamicanalyzer.widgets.da.base.DAButton; +import org.tizen.dynamicanalyzer.widgets.da.base.DADialog; +import org.tizen.dynamicanalyzer.widgets.da.base.DAMessageBox; +import org.tizen.dynamicanalyzer.widgets.da.base.WarningDialog; + +public class FilterDialog extends DAMessageBox { + private ScrolledComposite scrolledComposite = null; + private Composite filterInputComposite = null; + private DAButton addButton = null; + private DAButton clearButton = null; + private DAButton okButton = null; + + private DATableComposite ownTableComposite = null; +// private DAAdvancedViewComposite ownViewComposite = null; + private String compositeName = null; + private int selectedColumnIndex = -1; + + private List filterInputRowList = null; + private FilterColumn[] filterColumns = null; + private int visibleColumnCount = 0; + + private static final int FILTER_DIALOG_WIDTH = 434; + private static final int FILTER_DIALOG_HEIGHT = 306; + + class FilterColumn { + String columnName = null; + boolean isSelection = false; + + public FilterColumn(String columnName, boolean isSelection) { + this.columnName = columnName; + this.isSelection = isSelection; + } + + public String getColumnName() { + return columnName; + } + + public boolean getSelection() { + return isSelection; + } + + public void setSelection(boolean isSelection) { + this.isSelection = isSelection; + } + } + + public FilterDialog(Shell parentShell, /*DAAdvancedViewComposite ownView,*/ + DATableComposite composite, int selectedColumnIndex) { + super(parentShell); + + if (composite instanceof DATreeComposite) { + ownTableComposite = (DATreeComposite) composite; + } else if (composite instanceof DAWindowingTableComposite) { + ownTableComposite = (DAWindowingTableComposite) composite; + } else if (composite instanceof DATableComposite) { + ownTableComposite = (DATableComposite) composite; + } else { + Logger.error("This composite type is not supported !!"); + return; + } + + compositeName = ownTableComposite.getTableName(); + List allColumnName = ownTableComposite.getColumnsName(); + if (allColumnName == null) { + Logger.error("Cannot get all column name !!"); + return; + } + + boolean[] columnVisibility = ownTableComposite.getColumnVisibility(); + if (columnVisibility != null) { + filterColumns = new FilterColumn[columnVisibility.length]; + + for (int i = 0; i < columnVisibility.length; i++) { + if (columnVisibility[i] == true) { + filterColumns[i] = new FilterColumn(allColumnName.get(i), false); + visibleColumnCount++; + } else { + // do nothing!! + } + } + } else { + Logger.error("Column visibility data is wrong !!"); + return; + } + + if (selectedColumnIndex != -1) + this.selectedColumnIndex = selectedColumnIndex; + +// ownViewComposite = ownView; + filterInputRowList = new ArrayList(); + } + + private void initFilterInputRows() { + List filterPropertyList = null; + clearFilterInputRows(); + + filterPropertyList = ownTableComposite.getFilterPropertyList(); + if (filterPropertyList == null || filterPropertyList.isEmpty()) { + updateLayout(); + return; + } + + for (int i = 0; i < filterPropertyList.size(); i++) { + FilterProperty property = filterPropertyList.get(i); + int columnIndex = property.getColumnIndex(); + // set selected columns + filterColumns[columnIndex].setSelection(true); + FilterInputRow inputRow = null; + if (selectedColumnIndex != -1 && columnIndex == selectedColumnIndex) { + inputRow = new FilterInputRow(filterInputComposite, removeButtonListener, + comboMouseDownListener, true); + } else { + inputRow = new FilterInputRow(filterInputComposite, removeButtonListener, + comboMouseDownListener, false); + } + + inputRow.setComboText(filterColumns[columnIndex].getColumnName()); + inputRow.setKeyWordText(property.getKeyWord()); + inputRow.addSelectionListener(comboSelectionListener); + filterInputRowList.add(inputRow); + } + updateLayout(); + } + + private void updateLayout() { + filterInputComposite.layout(); + scrolledComposite.setMinSize(filterInputComposite.computeSize(SWT.DEFAULT, SWT.DEFAULT)); + clearButtonSetting(); + addButtonSetting(); + } + + private void clearButtonSetting() { + if (filterInputRowList.isEmpty()) { + clearButton.setButtonEnabled(false); + } else { + clearButton.setButtonEnabled(true); + } + } + + private void addButtonSetting() { + if (filterInputRowList.size() >= visibleColumnCount) { + addButton.setButtonEnabled(false); + } else { + addButton.setButtonEnabled(true); + } + } + + @Override + protected boolean run() { + if (ownTableComposite == null) + return false; + + shell.setLayout(new FormLayout()); + shell.setSize(FILTER_DIALOG_WIDTH, FILTER_DIALOG_HEIGHT); + shell.setBackground(ColorResources.FILTER_DIALOG_DEFAULT_BACKGROUND_COLOR); + shell.setText(AnalyzerLabels.FILTER_DLG_TITLE_PREFIX + CommonConstants.SPACE + + compositeName + CommonConstants.SPACE + AnalyzerLabels.FILTER_DLG_TITLE_POSTFIX); + + /* frame composite */ + Composite frameComposite = new Composite(shell, SWT.NONE); + FormData data = new FormData(); + data.top = new FormAttachment(0, 0); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(100, 0); + data.bottom = new FormAttachment(100, -47); + frameComposite.setLayoutData(data); + frameComposite.setLayout(new FormLayout()); + frameComposite.setBackground(ColorResources.DIALOG_BG_UPPER); + frameComposite.addPaintListener(new PaintListener() { + + @Override + public void paintControl(PaintEvent e) { + GC gc = e.gc; + + Composite comp = (Composite) e.widget; + Rectangle rect = comp.getClientArea(); + gc.setForeground(ColorResources.SETTING_SUNKEN_LINE_1); + gc.drawLine(0, rect.height - 1, rect.width - 1, rect.height - 1); + gc.setForeground(ColorResources.SETTING_SUNKEN_LINE_2); + gc.drawLine(0, rect.height, rect.width - 1, rect.height); + } + }); + + /* scrolled composite */ + scrolledComposite = new ScrolledComposite(frameComposite, + SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL); + data = new FormData(); + data.top = new FormAttachment(0, 6); + data.left = new FormAttachment(0, 6); + data.right = new FormAttachment(100, -6); + data.bottom = new FormAttachment(100, -35); + scrolledComposite.setLayoutData(data); + scrolledComposite.setLayout(new FormLayout()); + scrolledComposite.setExpandHorizontal(true); + scrolledComposite.setExpandVertical(true); + scrolledComposite.setBackground(ColorResources.FILTER_DIALOG_WHITE_BACKGROUND_COLOR); + + /* filter input composite */ + filterInputComposite = new Composite(scrolledComposite, SWT.NONE); + scrolledComposite.setContent(filterInputComposite); + scrolledComposite.setMinSize(filterInputComposite.computeSize(SWT.DEFAULT, SWT.DEFAULT)); + scrolledComposite.setShowFocusedControl(true); + data = new FormData(); + data.top = new FormAttachment(0, 5); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(100, 0); + data.bottom = new FormAttachment(100, 0); + filterInputComposite.setLayoutData(data); + filterInputComposite.setLayout(new FormLayout()); + filterInputComposite.setBackground(ColorResources.FILTER_DIALOG_WHITE_BACKGROUND_COLOR); + + /* buttons */ + clearButton = new DAButton(frameComposite, SWT.NONE); + data = new FormData(); + data.top = new FormAttachment(scrolledComposite, 3); + data.right = new FormAttachment(100, -6); + data.height = 22; + data.width = 60; + clearButton.setLayoutData(data); + clearButton.setText(AnalyzerLabels.FILTER_DLG_CLEAR_BUTTON); + clearButton.addClickListener(clearButtonListener); + + addButton = new DAButton(frameComposite, SWT.NONE); + data = new FormData(); + data.top = new FormAttachment(scrolledComposite, 3); + data.right = new FormAttachment(clearButton, -6); + data.height = 22; + data.width = 60; + addButton.setLayoutData(data); + addButton.setText(AnalyzerLabels.FILTER_DLG_ADD_BUTTON); + addButton.addClickListener(addButtonListener); + + okButton = new DAButton(shell, SWT.NONE); + data = new FormData(); + data.top = new FormAttachment(frameComposite, 11); + data.right = new FormAttachment(100, -9); + data.height = 28; + data.width = 100; + okButton.setLayoutData(data); + okButton.setText(WidgetLabels.OK); + okButton.addClickListener(okButtonListener); + + shell.open(); + initFilterInputRows(); + + return true; + } + + private DACustomButtonClickEventListener clearButtonListener = + new DACustomButtonClickEventListener() { + + @Override + public void handleClickEvent(DACustomButton button) { + WarningDialog dialog = new WarningDialog(shell, SWT.NONE); + dialog.setMessage(AnalyzerLabels.FILTER_DLG_CLEAR_MESSAGE); + boolean result = dialog.open(); + if (!result) { + return; + } else { + clearFilterInputRows(); + clearSelectedColumns(); + updateLayout(); + } + } + }; + + private DACustomButtonClickEventListener addButtonListener = + new DACustomButtonClickEventListener() { + + @Override + public void handleClickEvent(DACustomButton button) { + FilterInputRow inputRow = new FilterInputRow(filterInputComposite, + removeButtonListener, comboMouseDownListener, false); + inputRow.setComboText(getFirstSelectableColumnName()); + inputRow.addSelectionListener(comboSelectionListener); + filterInputRowList.add(inputRow); + updateLayout(); + } + }; + + private DACustomButtonClickEventListener okButtonListener = + new DACustomButtonClickEventListener() { + + @Override + public void handleClickEvent(DACustomButton button) { + ownTableComposite.clearFilterPropertyList(); + int size = filterInputRowList.size(); + for (int i = 0; i < size; i++) { + FilterProperty property = new FilterProperty(); + property.setColumnIndex(getColumnIndex(filterInputRowList.get(i) + .getCurrentlySelectedColumnName())); + String keyWord = filterInputRowList.get(i).getKeyWord(); + // check for keyword validation about null or empty string value + if (keyWord == null || keyWord.isEmpty()) { + DADialog dialog = new DADialog(shell, SWT.NONE); + dialog.setTitleText(WidgetLabels.DA_WARNING); + dialog.setMessage(AnalyzerLabels.FILTER_DLG_KEYWORD_VERIFICATION_MESSAGE); + dialog.setIcon(ImageResources.DIALOG_WARNING_ICON); + dialog.open(); + return; + } else { + property.setKeyWord(filterInputRowList.get(i).getKeyWord()); + } + ownTableComposite.addFilterProperty(property); + } + +// if (ownTableComposite instanceof CallstackTable) { +// if (ownViewComposite != null) { +//// DASelectionData selData = new DASelectionData(ownViewComposite.getID(), time, 0, ownTableComposite.getSelections(), ownTableComposite.getTable()); +// +// ((CallstackView) ownViewComposite).updateView(new DAViewData( +// ScreenshotTabComposite.tabID, null)); +// } else { +// Logger.debug("ownViewComposite is null !!"); +// } +// } else { +// ownTableComposite.updateTable(); +// } + ownTableComposite.updateTable(); + shell.close(); + } + }; + + private DACustomButtonClickEventListener removeButtonListener = new DACustomButtonClickEventListener() { + + @Override + public void handleClickEvent(DACustomButton button) { + // set value of isSelection of currently selected FilterColumn to false + FilterInputRow inputRow = (FilterInputRow) (button.getParent()); + int curColumnIndex = getColumnIndex(inputRow.getCurrentlySelectedColumnName()); + filterColumns[curColumnIndex].setSelection(false); + + // remove input row + removeFilterInputRow(inputRow.getCurrentlySelectedColumnName()); + updateLayout(); + } + }; + + private DACustomComboSelectionListener comboSelectionListener = new DACustomComboSelectionListener() { + + @Override + public void selectionEvent(DACustomCombo combo) { + String prevColumnName = ((FilterInputRow) (combo.getParent())) + .getCurrentlySelectedColumnName(); + String curColumnName = combo.getText(); + if (prevColumnName.compareTo(curColumnName) == 0) { + Logger.debug("same column is selected !!"); + return; + } + + changeColumnSelection(combo); + updateLayout(); + } + }; + + private Listener comboMouseDownListener = new Listener() { + + @Override + public void handleEvent(Event event) { + if (event.type == SWT.MouseDown) { + FilterInputRow inputRow = (FilterInputRow) ((DACustomCombo) (event.widget)) + .getParent(); + List columnNames = makeColumnNames(inputRow + .getCurrentlySelectedColumnName()); + inputRow.addColumnNameComboItems(columnNames); + } + } + }; + + private void clearFilterInputRows() { + for (int i = 0; i < filterInputRowList.size(); i++) { + filterInputRowList.get(i).dispose(); + } + filterInputRowList.clear(); + } + + // set value of isSelection of all FilterColumn to false + private void clearSelectedColumns() { + for (int i = 0; i < filterColumns.length; i++) { + FilterColumn col = filterColumns[i]; + if (col != null) { + col.setSelection(false); + } + } + } + + private void removeFilterInputRow(String columnName) { + FilterInputRow prev = null; + FilterInputRow cur = null; + FilterInputRow next = null; + + for (int i = 0; i < filterInputRowList.size(); i++) { + if (i != 0) + prev = cur; + + cur = filterInputRowList.get(i); + if (i != filterInputRowList.size() - 1) { + next = filterInputRowList.get(i + 1); + } else { + next = null; + } + + if (cur.getCurrentlySelectedColumnName().equalsIgnoreCase(columnName)) { + if (next != null) { + FormData nextData = (FormData) next.getLayoutData(); + if (prev != null) { + nextData.top = new FormAttachment(prev, 2); + } else { + nextData.top = new FormAttachment(0, 0); + } + } + + filterInputRowList.get(i).dispose(); + filterInputRowList.remove(i); + break; + } + } + } + + private void changeColumnSelection(DACustomCombo combo) { + FilterInputRow changedFilterInputRow = (FilterInputRow) (combo.getParent()); + swapSelectionState(changedFilterInputRow.getCurrentlySelectedColumnName(), combo.getText()); + changedFilterInputRow.setCurrentlySelectedColumnName(combo.getText()); + } + + private List getSelectableColumnNames() { + List selectableColumnNames = new ArrayList(); + + /* add selectable column names */ + for (int i = 0; i < filterColumns.length; i++) { + FilterColumn col = filterColumns[i]; + if (col != null && col.getSelection() == false) { + selectableColumnNames.add(col.getColumnName()); + } + } + + return selectableColumnNames; + } + + private String getFirstSelectableColumnName() { + for (int i = 0; i < filterColumns.length; i++) { + FilterColumn col = filterColumns[i]; + if (col != null && col.getSelection() == false) { + col.setSelection(true); + return col.getColumnName(); + } + } + + return CommonConstants.EMPTY; + } + + private List makeColumnNames(String selectedColumnName) { + List columnNames = new ArrayList(); + if (!selectedColumnName.isEmpty()) { + columnNames.add(selectedColumnName); + } else { + Logger.debug("selected column name is empty !!"); + } + + columnNames.addAll(getSelectableColumnNames()); + return columnNames; + } + + private int getColumnIndex(String columnName) { + for (int i = 0; i < filterColumns.length; i++) { + FilterColumn col = filterColumns[i]; + if (col != null + && col.getColumnName().compareTo(columnName) == 0) { + return i; + } + } + + Logger.error("There is not same column name - %s", columnName); + return -1; + } + + // set value of isSelection of previously selected FilterColumn to false + // & set value of isSelection of currently selected FilterColumn to true + private void swapSelectionState(String prevColumnName, String curColumnName) { + int prevColumnIndex = getColumnIndex(prevColumnName); + int curColumnIndex = getColumnIndex(curColumnName); + + if (prevColumnIndex == -1 || curColumnIndex == -1) { + Logger.error("Failed to change selection state !!"); + return; + } else { + filterColumns[prevColumnIndex].setSelection(false); + filterColumns[curColumnIndex].setSelection(true); + } + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterInputRow.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterInputRow.java new file mode 100644 index 0000000..92f7e4c --- /dev/null +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/FilterInputRow.java @@ -0,0 +1,210 @@ +/* + * Dynamic Analyzer + * + * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * Seokgil Kang + * Juyoung Kim + * WooJin Jung + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ + +package org.tizen.dynamicanalyzer.ui.widgets; + +import java.util.List; + +import org.eclipse.swt.SWT; +import org.eclipse.swt.graphics.Point; +import org.eclipse.swt.graphics.Rectangle; +import org.eclipse.swt.layout.FormAttachment; +import org.eclipse.swt.layout.FormData; +import org.eclipse.swt.layout.FormLayout; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Control; +import org.eclipse.swt.widgets.Listener; +import org.tizen.dynamicanalyzer.resources.ColorResources; +import org.tizen.dynamicanalyzer.resources.FontResources; +import org.tizen.dynamicanalyzer.resources.ImageResources; +import org.tizen.dynamicanalyzer.widgets.button.DACustomButton; +import org.tizen.dynamicanalyzer.widgets.button.DACustomButtonClickEventListener; +import org.tizen.dynamicanalyzer.widgets.button.DACustomButtonRenderer; +import org.tizen.dynamicanalyzer.widgets.combo.DACustomCombo; +import org.tizen.dynamicanalyzer.widgets.combo.DACustomComboSelectionListener; +import org.tizen.dynamicanalyzer.widgets.da.base.DATextBox; + +public class FilterInputRow extends Composite { + private DACustomCombo columnNameCombo = null; + private DATextBox keyWordText = null; + private DACustomButton removeButton = null; + private String currentlySelectedColumnName = null; + + public FilterInputRow(Composite parent, DACustomButtonClickEventListener removeListener, + Listener comboMouseDownListener, boolean isSelected) { + super(parent, SWT.BORDER); + if (isSelected) { +// this.setBackground(ColorResources.EXPLORER_SELECT_START); + this.setBackground(ColorResources.PAGE_CHART_SELECTION_BG); + } else { + this.setBackground(ColorResources.FILTER_DIALOG_WHITE_BACKGROUND_COLOR); + } + + Rectangle parentRect = parent.getBounds(); + Control lastChlid = null; + Control[] children = parent.getChildren(); + if (children.length - 1 > 0) { + lastChlid = children[children.length - 2]; + } + + FormData data = new FormData(); + if (lastChlid != null) { + data.top = new FormAttachment(lastChlid, 1); + } else { + data.top = new FormAttachment(0, 1); + } + data.height = 40; + data.left = new FormAttachment(0, 1); + data.width = parentRect.width - 5; + this.setLayoutData(data); + this.setLayout(new FormLayout()); + + /* column name combo */ + createColumnNameCombo(comboMouseDownListener); + data = new FormData(); + data.top = new FormAttachment(0, 8); + data.left = new FormAttachment(0, 10); + data.width = 124; + data.height = 24; + columnNameCombo.setLayoutData(data); + + /* key word text */ + keyWordText = new DATextBox(this, SWT.SINGLE); + keyWordText.setBackground(ColorResources.WHITE); + data = new FormData(); + data.top = new FormAttachment(0, 8); + data.left = new FormAttachment(columnNameCombo, 2); + data.width = 212; + data.height = 20; + keyWordText.setLayoutData(data); + + /* remove button */ + removeButton = new DACustomButton(this, + ImageResources.FILTER_DIALOG_DELETE_FILTER_NORMAL, + ImageResources.FILTER_DIALOG_DELETE_FILTER_PUSH, + ImageResources.FILTER_DIALOG_DELETE_FILTER_HOVER, + ImageResources.FILTER_DIALOG_DELETE_FILTER_NORMAL); + if (isSelected) { + removeButton.setBackground(ColorResources.PAGE_CHART_SELECTION_BG); + } else { + removeButton.setBackground(ColorResources.FILTER_DIALOG_WHITE_BACKGROUND_COLOR); + } + data = new FormData(); + data.top = new FormAttachment(0, 12); + data.right = new FormAttachment(100, -20); + data.width = 24; + data.height = 16; + removeButton.setLayoutData(data); + removeButton.addClickListener(removeListener); + } + + private void createColumnNameCombo(Listener comboMouseDownListener) { + columnNameCombo = new DACustomCombo(this, SWT.NONE); + columnNameCombo.setComboGradation( + ColorResources.TAB_COMBO_NORMAL_START, + ColorResources.TAB_COMBO_NORMAL_END, + ColorResources.TAB_COMBO_PUSH_START, + ColorResources.TAB_COMBO_PUSH_END, + ColorResources.TAB_COMBO_HOVER_START, + ColorResources.TAB_COMBO_HOVER_END, + ColorResources.FRAME_RATE_COMBO_DISABLE_START, + ColorResources.FRAME_RATE_COMBO_DISABLE_END); + columnNameCombo.setOutlineColors( + ColorResources.TAB_COMBO_NORMAL_STROKE, + ColorResources.TAB_COMBO_PUSH_STROKE, + ColorResources.TAB_COMBO_HOVER_STROKE, + ColorResources.FRAME_RATE_COMBO_OUTLINE_DISABLE); + columnNameCombo.setComboImages( + ImageResources.TAB_COMBO_BUTTON_DOWN, + ImageResources.TAB_COMBO_BUTTON_DOWN, + ImageResources.TAB_COMBO_BUTTON_DOWN, + ImageResources.TAB_COMBO_BUTTON_DOWN); + columnNameCombo.setComboImagePoint(new Point(108, 10)); + columnNameCombo.setButtonImages( + ImageResources.TAB_COMBO_BUTTON_DOWN, + ImageResources.TAB_COMBO_BUTTON_DOWN); + columnNameCombo.setFontPoint(new Point(7, 5)); + columnNameCombo.setEnabled(true); + columnNameCombo.setComboFont(FontResources.COMBO); + columnNameCombo.setItemFont(FontResources.DROPDOWN); + columnNameCombo.setFontColors( + ColorResources.ADD_CHART_FONT_COLOR, + ColorResources.ADD_CHART_FONT_COLOR, + ColorResources.ADD_CHART_FONT_COLOR, + ColorResources.ADD_CHART_FONT_COLOR); + columnNameCombo.setButtonRenderer(new DACustomButtonRenderer()); + columnNameCombo.addListener(SWT.MouseDown, comboMouseDownListener); + } + + public String getKeyWord() { + return keyWordText.getText(); + } + + public void setKeyWordText(String keyWord) { + keyWordText.setText(keyWord); + } + + public String getCurrentlySelectedColumnName() { + return currentlySelectedColumnName; + } + + public void setCurrentlySelectedColumnName(String columnName) { + currentlySelectedColumnName = columnName; + } + + public void setComboText(String columnName) { + columnNameCombo.add(columnName); + columnNameCombo.setText(columnName); + currentlySelectedColumnName = columnNameCombo.getText(); + } + + /** + * Adds column names to the Column name combo. + * + * @param columnNames + * column names + */ + public void addColumnNameComboItems(List columnNames) { + columnNameCombo.initCombo(); + for (int i = 0; i < columnNames.size(); i++) + columnNameCombo.add(columnNames.get(i)); + + columnNameCombo.setText(columnNames.get(0)); + currentlySelectedColumnName = columnNameCombo.getText(); + } + + /** + * Adds the listener to the Column name combo + * + * @param listener + * the listener which should be notified when the receiver is + * selected + */ + public void addSelectionListener(DACustomComboSelectionListener listener) { + columnNameCombo.addSelectionListener(listener); + } +} diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAApiListTableComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAApiListTableComposite.java index ad04745..c7240f2 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAApiListTableComposite.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAApiListTableComposite.java @@ -33,6 +33,7 @@ import java.util.List; import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.widgets.Composite; import org.tizen.dynamicanalyzer.common.AnalyzerConstants; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; public class DAApiListTableComposite extends DATableComposite { diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableComposite.java index 93085d5..f81b07f 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableComposite.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableComposite.java @@ -38,12 +38,16 @@ import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.SWT; import org.eclipse.swt.events.KeyEvent; import org.eclipse.swt.events.KeyListener; +import org.eclipse.swt.events.PaintEvent; +import org.eclipse.swt.events.PaintListener; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.graphics.Color; +import org.eclipse.swt.graphics.GC; import org.eclipse.swt.graphics.Image; import org.eclipse.swt.graphics.Point; +import org.eclipse.swt.graphics.Rectangle; import org.eclipse.swt.layout.FillLayout; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Event; @@ -54,6 +58,7 @@ import org.tizen.dynamicanalyzer.common.SymbolManager.SourceLine; import org.tizen.dynamicanalyzer.communicator.IDECommunicator; import org.tizen.dynamicanalyzer.constant.CommonConstants; import org.tizen.dynamicanalyzer.listeners.TableTooltipListener; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.FindProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.nl.TimelineChartLabels; @@ -64,6 +69,7 @@ import org.tizen.dynamicanalyzer.swap.model.data.LogData; import org.tizen.dynamicanalyzer.ui.common.PopupAnalysisMenuItemClickListener; import org.tizen.dynamicanalyzer.ui.range.RangeDataManager; import org.tizen.dynamicanalyzer.ui.widgets.DAGrid; +import org.tizen.dynamicanalyzer.ui.widgets.FilterDialog; import org.tizen.dynamicanalyzer.ui.widgets.FindDialog; import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.dynamicanalyzer.util.WorkbenchUtil; @@ -80,6 +86,9 @@ public abstract class DATableComposite extends Composite { protected DATableComposite me = null; protected static FindProperty findProferty; protected boolean ctrlPressed = false; + + // for filter + protected List filterPropertyList; protected Grid table; protected List selectionIndex; @@ -111,6 +120,9 @@ public abstract class DATableComposite extends Composite { protected RangeDataManager rangeDataManager = RangeDataManager .getInstance(); + + protected static final Image filterImg = ImageResources.COLUMN_FILTER_NORMAL; + protected static final int filterImgOffset = 12; public DATableComposite(Composite parent, int style) { this(parent, SWT.NONE, style); @@ -140,6 +152,7 @@ public abstract class DATableComposite extends Composite { me = this; setTableToolTipListener(new TableTooltipListener(table)); + applyFilterImage(); } protected Grid createGrid(int tableStyle) { @@ -291,22 +304,35 @@ public abstract class DATableComposite extends Composite { } column.pack(); - - if (null != comparator && null != sortTypes) { - final int type = sortTypes[i]; - // final int sourceColumn = sourceColumns[i]; - final int columnIndex = i; - - column.addSelectionListener(new SelectionAdapter() { - public void widgetSelected(SelectionEvent event) { - comparator.setType(type); - comparator.setColumn(columnIndex); - // comparator.setSourceColumn(sourceColumn); - comparator.reverseDirection(); - updateTable(); + + final int columnIndex = i; + column.addSelectionListener(new SelectionAdapter() { + public void widgetSelected(SelectionEvent event) { + if (checkAndOpenFilterDialog(columnIndex)) { + return; + } else { + if (null != comparator && null != sortTypes) { + comparator.setType(sortTypes[columnIndex]); + comparator.setColumn(columnIndex); + // comparator.setSourceColumn(sourceColumns[columnIndex]); + comparator.reverseDirection(); + updateTable(); + } } - }); - } + } + }); + } + } + + public void setColumns(String[] columnNames, int[] headerAlignmentStyle) { + this.setColumns(columnNames); + if (columnNames.length != headerAlignmentStyle.length){ + Logger.error("Count of columnNames is not the same as the count of headerAlignmentStyle!"); + return; + } + for (int i = 0; i < columnNames.length; i++) { + GridColumn column = table.getColumn(i); + column.setHeaderRenderer(new DATableHeaderRenderer(headerAlignmentStyle[i])); } } @@ -322,6 +348,21 @@ public abstract class DATableComposite extends Composite { } return dbColumnsName; } + + public boolean[] getColumnVisibility() { + if (null == table) + return null; + + GridColumn[] columns = table.getColumns(); + int size = columns.length; + boolean[] columnsVisibility = new boolean[size]; + + for (int i = 0; i < size; i++) { + columnsVisibility[i] = columns[i].getVisible(); + } + + return columnsVisibility; + } public void setColumnVisibility(boolean[] columnVisibility) { if (null == table || null == columnVisibility) { @@ -377,6 +418,7 @@ public abstract class DATableComposite extends Composite { selSeqs.add(tableData.getSelectionKey()); } } + table.removeAll(); List input = makeTableInput(); @@ -463,6 +505,8 @@ public abstract class DATableComposite extends Composite { table.removeAll(); getSelectionIndex().clear(); getSelections().clear(); + if (filterPropertyList != null) + filterPropertyList.clear(); } public void setComparator(DefaultTableComparator comparator) { @@ -597,6 +641,26 @@ public abstract class DATableComposite extends Composite { public static void setFindProferty(FindProperty findProferty) { DATableComposite.findProferty = findProferty; } + + private void initFilterPropertyList() { + if (filterPropertyList == null) + filterPropertyList = new ArrayList(); + } + + public List getFilterPropertyList() { + initFilterPropertyList(); + return Collections.unmodifiableList(filterPropertyList); + } + + public void addFilterProperty(FilterProperty filterProperty) { + initFilterPropertyList(); + filterPropertyList.add(filterProperty); + } + + public void clearFilterPropertyList() { + initFilterPropertyList(); + filterPropertyList.clear(); + } protected void actionSetStartEnd(int type) { GridItem item = table.getItem(mousePoint); @@ -797,4 +861,102 @@ public abstract class DATableComposite extends Composite { this.itemHeightSize = itemHeightSize; table.setItemHeight(itemHeightSize); } + + protected void applyFilterImage() { + table.addPaintListener(new PaintListener() { + + @Override + public void paintControl(PaintEvent e) { + GC gc = e.gc; + GridColumn[] columns = table.getColumns(); + List filerProperties = getFilterPropertyList(); + for (int i = 0; i < filerProperties.size(); i++) { + int columnIndex = filerProperties.get(i).getColumnIndex(); + if (columns[columnIndex].isVisible()) { + gc.drawImage(filterImg, getFilterImagePosition(columnIndex), 0); + } + } + } + }); + } + + protected int getFilterImagePosition(int columnIndex) { + int position = 0; + if (table.getHorizontalBar() != null) { + if (table.getHorizontalBar().getSelection() > 0) + position -= table.getHorizontalBar().getSelection(); + } + + GridColumn[] columns = table.getColumns(); + for (int i = 0; i <= columnIndex; i++) { + if (columns[i].isVisible()) { + position += columns[i].getWidth(); + } + } + + return position - filterImgOffset; + } + + protected boolean isFilterAppliedColumn(int columnIndex) { + boolean flag = false; + List filterProperties = getFilterPropertyList(); + if (!filterProperties.isEmpty()) { + for (int i = 0; i < filterProperties.size(); i++) { + if (columnIndex == filterProperties.get(i).getColumnIndex()) { + flag = true; + break; + } + } + } + + return flag; + } + + protected boolean checkAndOpenFilterDialog(int columnIndex) { + // check if this column applies filter + if (!isFilterAppliedColumn(columnIndex)) { + return false; + } else { + int pos = getFilterImagePosition(columnIndex); + if (mousePoint.x < pos || mousePoint.x > pos + filterImgOffset + || mousePoint.y > filterImgOffset) { + return false; + } else { + Shell shell = WorkbenchUtil.getWorkbenchWindow() + .getShell(); +// FilterDialog filterDialog = new FilterDialog(shell, null, me, +// columnIndex); + FilterDialog filterDialog = new FilterDialog(shell, me, columnIndex); + filterDialog.open(); + return true; + } + } + } + + protected String getFilteredColumnName(int columnIndex) { + return null; + } + + protected String addLowerOperation(String columnName) { + return "lower" + CommonConstants.OPEN_BRACKET + columnName + CommonConstants.CLOSE_BRACKET; + } + + protected String makeFilterWhereClause(String columnName, String keyword) { + return columnName + CommonConstants.SPACE + "like" + CommonConstants.SPACE + "'" + + CommonConstants.PERCENT + keyword.toLowerCase() + CommonConstants.PERCENT + "'"; + } + + protected List convertFilterProperty2Query(List filterList) { + List queries = new ArrayList(); + + for (int i = 0; i < filterList.size(); i++) { + FilterProperty prop = filterList.get(i); + String column = getFilteredColumnName(prop.getColumnIndex()); + if (column != null) { + queries.add(makeFilterWhereClause(column, prop.getKeyWord())); + } + } + + return queries; + } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableEmptyCellRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableEmptyCellRenderer.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableHeaderRenderer.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableHeaderRenderer.java index 12cefba..ee66b04 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableHeaderRenderer.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATableHeaderRenderer.java @@ -67,7 +67,7 @@ public class DATableHeaderRenderer extends DefaultColumnHeaderRenderer { if ((style & SWT.LEFT) == SWT.LEFT) { this.alignment = SWT.LEFT; } else if ((style & SWT.RIGHT) == SWT.RIGHT) { - this.alignment = SWT.LEFT; + this.alignment = SWT.RIGHT; } else { this.alignment = SWT.CENTER; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATreeComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATreeComposite.java index 3e6b0f1..6c403f1 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATreeComposite.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DATreeComposite.java @@ -36,7 +36,9 @@ import org.eclipse.nebula.widgets.grid.Grid; import org.eclipse.nebula.widgets.grid.GridItem; import org.eclipse.swt.SWT; import org.eclipse.swt.graphics.Image; +import org.eclipse.swt.graphics.Rectangle; import org.eclipse.swt.widgets.Composite; +import org.tizen.dynamicanalyzer.model.FilterProperty; import org.tizen.dynamicanalyzer.model.TableInput; import org.tizen.dynamicanalyzer.model.TreeInput; import org.tizen.dynamicanalyzer.util.Logger; @@ -58,6 +60,7 @@ public abstract class DATreeComposite extends DATableComposite { public DATreeComposite(Composite parent, int compStyle, int tableStyle) { super(parent, compStyle, tableStyle); + applyFilterImage(); } protected HashMap getExpandMap() { @@ -175,9 +178,8 @@ public abstract class DATreeComposite extends DATableComposite { selSeqs.add(tableData.getSelectionKey()); } table.removeAll(); - - List input = makeTreeInput(); - + + List input = makeTreeInput(); if (null == input) { return; } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAWindowingTableComposite.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAWindowingTableComposite.java index 8f6cbb3..a3c73f7 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAWindowingTableComposite.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/widgets/table/DAWindowingTableComposite.java @@ -53,6 +53,7 @@ import org.tizen.dynamicanalyzer.resources.ColorResources; import org.tizen.dynamicanalyzer.ui.widgets.DAGrid; import org.tizen.dynamicanalyzer.ui.widgets.FindDialog; import org.tizen.dynamicanalyzer.util.CommonUtil; +import org.tizen.dynamicanalyzer.util.Logger; import org.tizen.dynamicanalyzer.util.WorkbenchUtil; public abstract class DAWindowingTableComposite extends DATableComposite { @@ -371,7 +372,7 @@ public abstract class DAWindowingTableComposite extends DATableComposite { } else if (object instanceof Long) { totalItemCount = ((Long) object).intValue(); } else { - System.out.println("[ERR] result of item count query is not expected!!"); + Logger.error("result of item count query is not expected!!"); totalItemCount = 0; } } diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/utils/AnalyzerUtil.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/utils/AnalyzerUtil.java old mode 100755 new mode 100644 diff --git a/org.tizen.dynamicanalyzer/test/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDBTest.java b/org.tizen.dynamicanalyzer/test/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDBTest.java index c915715..561dcfa 100644 --- a/org.tizen.dynamicanalyzer/test/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDBTest.java +++ b/org.tizen.dynamicanalyzer/test/src/org/tizen/dynamicanalyzer/ui/file/data/FileApiDBTest.java @@ -61,7 +61,7 @@ public class FileApiDBTest { accessorDB.insert(accessor); // when the parent row is selected - ResultSet rs = apiDB.selectAPI(2, 1, true); // fileId, accessorId, isParent + ResultSet rs = apiDB.selectAPI(2, 1, true, null); // fileId, accessorId, isParent if (rs != null) { try { while (rs.next()) { diff --git a/os_stubs/macos/dynamic-analyzer.sh b/os_stubs/macos/dynamic-analyzer.sh old mode 100644 new mode 100755 diff --git a/package/build.linux b/package/build.linux old mode 100755 new mode 100644 diff --git a/package/dynamic-analyzer-product.install.linux b/package/dynamic-analyzer-product.install.linux old mode 100755 new mode 100644 diff --git a/package/dynamic-analyzer-product.remove.linux b/package/dynamic-analyzer-product.remove.linux old mode 100755 new mode 100644 diff --git a/test/setting/setting b/test/setting/setting old mode 100755 new mode 100644 -- 2.7.4